Start here

Principles

The language is small on purpose. Once these ideas make sense, the rest of the guide is detail.

1. One tree, two views

The canvas and the code are two views of the same widget tree. Code is never exported and re-imported: when you apply an edit, the tree changes, and the next time you open the editor the code is printed fresh from it. Anything you can draw you can write, and the other way round.

Because the code is printed from the tree, formatting comes back tidy. The editor keeps your comments, though, so notes you leave stay where you put them.

2. Widgets, not HTML

Tags are widgets: Column, Row, Stack, Text, Image, FilledButton. The names follow Flutter's, so they say what a thing does rather than how it's drawn. There's no div or span. Every widget has a fixed set of props, and the editor tells you when one doesn't exist.

Widgets come in two kinds. Layouts arrange other widgets (a Row places children side by side, a Padding insets one). Elements are the things people see: text, images, buttons, chips. See the widget reference.

3. Every layer has one root

A layer is a single widget and everything inside it. Code for a layer has exactly one outermost tag. To place two things together, choose how they sit: a Column stacks them, a Row lines them up.

<Column className="gap-2">
  <Text>Winter sale</Text>
  <Text>Up to 40% off</Text>
</Column>

4. Data stays live

Product names, prices and images are never pasted in. You point at them: {product.price}, products({ limit: 8 }). The storefront fills them in at request time, so a price change, a new product or a sold-out size shows up without touching the page. See Store data.

5. Mobile first

A plain value is the phone value. Breakpoint prefixes (md:, lg:) override it from that width up. Sizes respond to the width of the page area, not the browser window, so the builder's phone, tablet and desktop previews show exactly what visitors see. See Responsive design.

6. Sections are just widgets

A hero, a category grid, the header, the product page: each is an ordinary widget tree whose root carries a name such as slot="section:categories". Nothing is hidden behind a special block. You can restyle, rearrange or rewrite any part, and the builder's section tools still find the pieces they manage. See Sections.

7. Utilities are shorthand for props

className="p-6 rounded-xl" isn't CSS. Each class sets a widget prop (padding, radius, colour), the same prop the properties panel edits. A class the widget can't use is flagged, not silently ignored. See Styling.

8. Mistakes explain themselves

The editor never guesses quietly. A misspelt widget or prop gets a "did you mean", a slug that doesn't match your catalog names the closest one, and a widget placed where it can't go says where it can. Errors block applying; warnings (like linking to a draft product) let you continue.