Syntax
Components are defined using special curly braces{%
and %}
tags.
/
at the start of a line.
Component Names
Component names are:- Declarative: they describe what type of UI element will be rendered
- Snake case: they are written in snake_case
- Validated: if you type an invalid component name, the editor will underline it in red
Attributes
Attributes define the configuration of the component. Attbutes are:- Required or Optional: For a given component
- Typed:
- String
data="demo_order_details"
- Number
limit=20
- Boolean
stacked=true
- Object
x_axis_options={title='Date'}
- String
- Auto-completed: When you hit enter or space, the editor will show a list of available attributes
- Validated: if you type an invalid attribute name, or provide an invalid value, the editor will underline it in red, and provider detailed error messages on hover
Self Closing Components
Some components contain content./
at the end of the first example replaces the {% /table %}
tag.
Only components that do not require content can be self closed.