- Editing an existing field is anchor-driven. If it renders with
data-e-path, it is editable. - Adding needs to know the shape of the thing being added. That is the schema.
Singleton or list
The schema marks the lists and describes the item shape. Everything else is a singleton by default.
A schema entry
lib/admin-schema.ts exports the object mountAdmin receives. Per component type:
Form field types:
text, textarea, url, toggle, select, list (with itemKey), media (with videoKey). showIf: { key, value } hides a field until a toggle flips, and hidden fields skip validation.
Reflected keys
A settings-cog field whose value the renderer mirrors straight onto the DOM (arequired attribute, a placeholder) can be applied in place with no re-render. Anything else re-renders the component staged.
What else the schema declares
The schema is the site’s. The admin package is generic and reads whatever it is handed.
Next steps
The edit notch
The constraint and the contract.
Blog
Give a site articles.