6. Understand the boundaries
luastra/ui · luastra/data · controlled input · about 20 minutesinput → state → decode → domain rule → review → commit
Static types, runtime schemas, application rules, and accessible presentation solve different parts of the form.
When to use it
Read this before adding persistence, server submission, or more fields.
- Luau types check your code; Data.decode validates values received at runtime.
- Data string limits count UTF-8 bytes, not visible characters.
- The email pattern is a small UI check, not proof that an address exists or can receive mail.
- Clear a field error when that field changes, then validate the complete form again on Review.
- Keep the modal in the tree with open=false so the host can close it and restore focus deterministically.