Skip to content
@teasim/astro documentation

@teasim/astro

The content layer — navigation, validation, markdown twins, and machine-readable routes.

@teasim/astro is the half of a documentation site that has nothing to do with how it looks. It validates content, computes navigation, and publishes human and machine-readable routes without rendering a component.

Install

sh
bun add @teasim/astro

Register teasim() in astro.config.mjs, then define collections with contentCollection() so their mounts can be shared by HTML pages, markdown twins, and llms.txt.

Core responsibilities

  • Validate content while naming the entry that needs attention
  • Build sidebars, breadcrumbs, table-of-contents data, and previous/next links
  • Serve a .md twin for every published page
  • Generate llms.txt and llms-full.txt from the same content

Why it is separate

A content helper that also renders markup decides how your site is built. That is a borrowed decision, so computing stays separate from rendering: @teasim/astro renders nothing, while @teasim/astra and @teasim/aster know nothing about content. Either half works on its own.

Validation that names the page

Schema problems are reported in development with the slug that caused them. A missing title, a link that points nowhere, or a prev value that names a page that does not exist becomes a useful message naming the file.

Continue reading

See Project structure for a complete site scaffold and createNavigation for the navigation API.