← Back
Conditional
Content inside of an aside component will be displayed in the margin of your document. The conditional component will only display its children when a condition is met:
Input:
[var name:"showChart" value:false /]
[Button onClick:`showChart = !showChart`]
[Display value:`showChart ? 'Hide Chart' : 'Show Chart' ` /]
[/Button]
[Conditional if:`showChart`]
[Chart /]
[/Conditional]
Output:
Props
- if
expression
An expression; if this evaluates to true, the children will be rendered, otherwise nothing will be drawn to the screen
- Example:
`true`
- Example: