Components
Component files are used to define the interface of your application. They allow you to create reusable visual elements throughout your project.

Component configuration
When selecting a component file, you'll get a few configuration options in the inspector panel. Here are the most common ones:
- Component - This allows you to toggle between the page and component mode, as well as changing the preview mode (see Preview), and to add a model.
- Properties - Here, you can add custom properties which will be available as variable inside your component.
- Variables - Those will be the variables you want to use, but not exposed as properties.
- Computed - The computed variables are variables whose value is automatically recalculated based on other variables or conditions.
- Events - This is where you can define the events that can be triggered by your component.
- Default - In this section, you can write the default value of your properties and variables.
Layout tree
The layout tree accessible in the options panel allows you to build the architecture of your component. To add an element to the tree, simply click on the button (see Builder for every way to insert elements). Some elements can have children. These slots for children are called slots.
Here are a few options at your disposal for each layout element, here are the most common ones:
- Block - Most basic element type, it's just a box that can have children.
- Component - Use one of the custom components you created.
- Slot - Indicate where the children of this component should go.
- Template - This allows you to do conditional or loop rendering.
- Custom text - Write formatted text, with variables (see Text).
- Custom HTML - Write custom HTML code.
- Variable - Use this kind of element to display a variable.
Model
A model is a value shared both ways between a component and the component that uses it, like the value of a text field: the parent gives a variable, the component reads it and can change it, and the parent's variable follows. Use it for components that edit a value: a rating, a color picker, a custom input.
Add a model
- Click the component in the Explorer. In the Component section of the inspector, click Add model in the Model row.
- Pick its type (for example Number for a rating).
A component has one model. Pages don't have one. The × of the row removes it.

Use it inside the component
- In the logic, the Get Model node reads the model, and Set Model changes it.
- In the bindings, the model is listed as
<Component name> Model.
Bind it from a parent
Select an instance of the component in the parent's layout tree. The Element panel shows a Model row: pick the variable to share. New variable in the picker creates one of the right type.
When the component calls Set Model, the parent's variable changes, and when the parent changes its variable, the component's model follows.

The same Model row binds the value of an Input element, and of plugin components that have a value (a select, a checkbox...). Some plugin components have several models: add the others with the + of the Models row.
TIP
The model has no default value in the exported app: always bind it in the parent. In the editor, an unbound model starts at the default value of its type.
Pages
To define a component as a page, simply change its type in the inspector. You can then define a path to access the page. The main page of your application will always be / (with nothing following). See Pages and Navigation for paths, dynamic segments, and links between pages.