Skip to main content
zerotal

Documentation


Documentation / @zerotal/flow / index / Flash

Function: Flash()

Flash(props?): HtmlNode

Defined in: flow/src/components.ts:277

The toast host — a single fixed container plus the client runtime that renders flash messages emitted by the server (via flow:flash window events) as styled, self-dismissing toasts. Place it once, near the root of your layout.

Parameters

props?

FlashProps = {}

Returns

HtmlNode

Remarks

position (default "bottom-right") and duration in ms (default 4000) are the defaults for toasts that don't specify their own; individual toasts can override position, duration, icon, actions and more via the emitted payload.

Example

<Flash position="top-right" duration={6000} />