behaviours
look
A screen carries small rules: a field's checks, when a field shows, when a control is on. The renderer runs them as you type; nothing goes to a server. With JS off, each block shows its start state and the page still reads.
Try it
ada@example.orgemail
falseupdates
monthlyoften
signed
The rules on this screen
email.checks.ok: {"is":{"value":{"get":"email"},"pattern":"email"}}
often.show: {"get":"updates"}
sign-up.enabled: {"is":{"value":{"get":"email"},"pattern":"email"}}Where they run
Webblocks.js runs them on each keystroke
SwiftUIthe same rules, the same messages
Static page, JS offthe start state, as it reads before any typing
Every page here is a blocks
Screen, written by site::page: no hand-written HTML. Source: https://github.com/jirathip-dev/blocks