Collection Rules
Validation rules for collections — schema-less records, empty records, errors.
Records without a schema
---
~ John Doe, 20, female
~ true, false
~ marketing, 123, { Z Street, Los Angeles, CA }Empty records
~ $schema: { name?*: string, age?*: { int, max: 25 } }
---
~ John, 25 # ✓
~ William # ✓ (age omitted)
~ # ✓ (empty object; all fields optional/nullable)~ $schema: { name: string, age?*: { int, max: 25 } }
---
~ John, 25 # ✓
~ # ✗ value-required — name is requiredIndependent validation & error handling
See Also
Last updated
Was this helpful?
