Design principles
The principles that keep Ginko content, routes, queries, and integrations predictable.
Files are canonical
With the filesystem provider, authored files are the source of truth. Parsed caches, normalized documents, locale indexes, navigation, search records, sitemap entries, and prerender routes are derived and can be rebuilt.
An external provider takes the place of the filesystem as source of truth. It still returns source facts through the provider contract; Ginko applies the same public document and route model.
Every read belongs to a collection
Queries require a collection handle or name. The collection fixes the source, schema, route mount, locale behavior, sitemap policy, and provider boundary before a read runs. Exported handles also preserve schema inference in application code.
Routes are data, not guesses
Route-backed page documents carry route.resolvedPath, route.alternates, and resolution. Applications render those facts instead of rebuilding URLs from file paths, IDs, or locale conventions. Data-collection records have no public page route and should not be rendered as links.
Processing has one direction
- Discover files or receive raw provider documents.
- Parse and transform Markdown or structured data, including deterministic custom transforms and source-path metadata.
- Expand locales into the document variants defined by the collection.
- Validate each variant against the collection schema and JSON-safe document contract.
- Project the validated documents into public query and route facts.
- Consume the result in pages, queries, navigation, search, sitemaps, and agent-readable output.
All consumers use the normalized document. They do not independently reinterpret the source file.
Integrations keep their native responsibilities
| Owner | Responsibility |
|---|---|
| Ginko | Collections, normalized documents, queries, route projection, rendering integration |
| Provider | Source documents, supported query capabilities, source invalidation |
| Nuxt | Application routes, rendering, Nitro deployment, prerender execution |
| Nuxt I18n | Active locale and application URL strategy |
| Nuxt Sitemap | XML generation, sitemap indexes, and robots integration |
| Application | Layouts, 404 behavior, access policy, and product-specific queries |
| CMS | Editing, publishing, roles, assets, workflow, and editorial history |