API Overview
Ornata currently exposes three runtime exports for defining components and enhancing HTML:
defineComponentcreateInitializerisComponent
The main authoring workflow starts with defineComponent(), then uses mount() directly or createInitializer() for declarative bootstrapping.
Main exports
Section titled “Main exports”defineComponent()
Section titled “defineComponent()”Creates an Ornata component constructor from typed component options.
createInitializer()
Section titled “createInitializer()”Creates a function that scans the document for data-ornata roots and mounts matching components.
isComponent()
Section titled “isComponent()”Checks whether a value is an Ornata component constructor.
What a component constructor exposes
Section titled “What a component constructor exposes”A component constructor returned by defineComponent() includes:
displayNamemount()getInstance()findInstance()unmount()
See Component Instance for the mounted instance API and lifecycle details.