@siteswarm/cms
@siteswarm/cms
Section titled “@siteswarm/cms”Headless content management capability engine, EmDash Cloudflare D1 adapter, tiered studio feature gating, and schema registry engine for SiteSwarm applications.
Overview
Section titled “Overview”@siteswarm/cms provides the shared runtime foundation for client applications using EmDash CMS (emdash and @emdash-cms/cloudflare). It standardizes:
- Tiered Feature Gating: Standardized
lite,standard, andfulltiers suppressing non-essential blogging chrome in the EmDash Admin Studio. - Admin Middleware: Protects disabled feature endpoints with
403 Forbidden, redirects unneeded routes, and injects scoped suppression CSS into the admin HTML shell. - D1 Schema Registry: Idempotent table creation and collection/field synchronization into
_emdash_collectionsand_emdash_fields. - Query Safety: Draft-gated and deleted-isolated query runners (
getPublishedEntries) preventing draft leaks to public frontends. - Dev Admin Bootstrap: Instant auto-login and setup completion flags for local development and ephemeral PR previews.
Subpath Exports
Section titled “Subpath Exports”.: Universal entry point (re-exports schemas and server utilities)../schemas: Pure TypeScript types, tier definitions, and options schemas../server: Cloudflare edge runtime adapters, D1 resolvers, query helpers, and middleware.