v0.17.171 - 39.7 / 23.3

<Collapse .../>

Similar to <Show/> , it renders its children based on a condition, the difference is that the element is not removed from the document if the condition becomes falsy. Useful for iframes, canvas, video, audio.

# Attributes

nametypedescription
whenanyonce when becomes truthy, it will show its children
fallbackanywhen `falsy` a fallback could be displayed

# Snippet

# Reactive

A youtube video keeps playing in the background even if the collapse element is set to be hidden

# Fallback

A youtube video keeps playing in the background and a fallback is shown