@zelavis/database
@zelavis/database provides the core database contracts and document primitives for Zelavis.
Current role
Section titled “Current role”The package is event-first internally.
Current public shape centers on:
- documents
- events
- schemas
- native file-reference schema fields
- projections
- time-series
- optional SQL capability
Important current constraints
Section titled “Important current constraints”Current non-goals for the first slice include:
- built-in SQLite dependency in core
- replication
- offline sync
- distributed transactions
Current design direction
Section titled “Current design direction”- document APIs remain the main ergonomic surface
- writes append events
- reads come from projections
- projections are explicit public contract metadata
- time-series builds on that explicit model
- collection schemas can now validate Zelavis-style file references with
type: "file"or helpers such asimageFileSchema(...),audioFileSchema(...),videoFileSchema(...), anddocumentFileSchema(...) - editor-facing content models can mark rich-text HTML fields explicitly with
richTextHtmlSchema(...), which the dashboard maps to Lexical while the stored value remains plain HTML