Skip to content

@continuum-js/dom


@continuum-js/dom / Show

Function: Show()

Show<T>(props): Node

Defined in: index.tsx:1004

Conditional region. Rebuilds only when the truthiness of when toggles; the (narrowed) value is passed to the children render function at build time.

tsx
<Show when={user} fallback={() => <Guest />}>
  {(u) => <span>{u.name}</span>}
</Show>

Type Parameters

T

T

Parameters

props

children

(value) => Child

fallback?

() => Child

when

State<T>

Returns

Node