Skip to content

Core Concepts

Understanding these fundamental concepts is sufficient to author any StemJSON screen.

ConceptOne-line definition
ComponentA JSON object node in the render tree. Can be visual (text, button) or non-visual (module, conditional).
ModuleNon-visual root that owns isolated state and a dependency registry for one screen or feature.
TemplateA proxy component that renders a reusable component pulled from the dependency registry.
ContextA component-scoped property dictionary. Public keys (not prefixed _) are inherited by children; private keys are not.
StateMutable data owned exclusively by a module. State changes trigger re-rendering of the module subtree.
StyleVisual and layout modifiers grouped into named domains (layout, common, navigation, button, shape, animation, modal, text, textField, scroll, swipe, shadow, datePicker, section, map, grid, video, pdf, picker, accessibility).
EventA named trigger (e.g. onTap, onAppear) mapped to an ordered array of actions.
ActionAn executable unit triggered by an event or chained from another action. The sole mechanism for side effects. Co-declared actions (multiple actions in the same event array) run in parallel; chained actions (output.success / output.failure) run sequentially.
RepositoryA typed dependency providing CRUD data access — local, secured, remote, or firebase.
SourceA scheme-prefixed string locator for dependencies, assets, localization keys, and URLs.