Toast
uitemplate
Enable screen reader announcements (default: true)
Terminal
$termuijs render toast
Installation
$ bunx termuijs add toast
Copies the source into src/components/toast/ and installs @termuijs/core, @termuijs/widgets.
Usage
ts
import { Toast } from '@termuijs/ui'ts
new Toast(options: ToastOptions = {})API Reference
Toast
| Prop | Type | Required | Description |
|---|---|---|---|
position | 'top-right' | 'bottom-right' | 'top-left' | 'bottom-left' | optional | — |
durationMs | number | optional | — |
maxVisible | number | optional | — |
announce | boolean | optional | Enable screen reader announcements (default: true) |