Content Authoring
Canonical source of truth: packages/content/resources/<slug>/. Full reference: CONTENT_AUTHORING.md.
When to use
- Any new Library resource (component, pattern, prompt, animation, schema, boilerplate, …)
- Editing frontmatter, snippets, or README prose for an existing resource
- After content changes that affect the MCP catalog
Quick start
packages/content/resources/my-resource/
index.mdx
snippets/
html.html # if targets includes html
style.css
script.js
react.tsx # if targets includes react
Minimum valid frontmatter
---
slug: my-resource
title: My Resource
description: One sentence explaining what it is.
category: ui-components
type: component
difficulty: med
createdAt: 2026-06-12
updatedAt: 2026-06-12
---
Recommended frontmatter
Add tags, tech, targets, collections, labRoute, license, and author for discoverability.
Category ↔ type pairs
| Category |
Type |
Use for |
ui-components |
component |
Buttons, forms, cards, widgets |
components |
component |
React-oriented reusable blocks |
pages |
page |
Full page layouts → see page-resources |
web-animations |
animation |
Motion, scroll, canvas, WebGL |
patterns |
pattern |
UX interaction patterns |
prompts |
prompt |
AI prompt templates |
skills |
skill |
Agent skill definitions |
database-schemas |
schema |
SQL / ERD resources |
recommendations |
recommendation |
Tool comparison topics (no code, no Lab) |
Do not invent new category/type values without updating the schema (see add-collection for the wiring list).
Snippet targets
| Target |
File |
html |
snippets/html.html |
react |
snippets/react.tsx |
next |
snippets/next.tsx |
vue |
snippets/vue.vue |
svelte |
snippets/svelte.svelte |
astro |
snippets/astro.astro |
typescript |
snippets/typescript.ts |
sql |
snippets/schema.sql, seed.sql, queries.sql |
markdown |
snippets/markdown.md |
Only declare targets you actually ship.
Lab demos
Set labRoute: /<category>/<slug> and provide html.html (+ linked style.css / script.js). Lab inlines assets at build time in apps/lab.
Post-change commands
bun run --filter @stealthis/mcp catalog
bun run lint
bun run build:www
bun run build:lab # if labRoute set
bun run build:mcp # if metadata affects MCP tools
Schema alignment
If you add fields or enum values, update in the same PR:
packages/schema/src/schema.ts
packages/schema/src/types.ts
apps/www/src/content/config.ts
apps/www/src/i18n/index.ts (labels/filters)
Checklist
1---2name: content-authoring3description: Add or edit library resources in packages/content/resources with frontmatter, snippets, and MCP catalog regeneration. Use for any new resource type — components, patterns, prompts, animations, schemas, etc.4---56# Content Authoring78Canonical source of truth: `packages/content/resources/<slug>/`. Full reference: `CONTENT_AUTHORING.md`.910## When to use1112- Any new Library resource (component, pattern, prompt, animation, schema, boilerplate, …)13- Editing frontmatter, snippets, or README prose for an existing resource14- After content changes that affect the MCP catalog1516## Quick start1718```19packages/content/resources/my-resource/20 index.mdx21 snippets/22 html.html # if targets includes html23 style.css24 script.js25 react.tsx # if targets includes react26```2728### Minimum valid frontmatter2930```mdx31---32slug: my-resource33title: My Resource34description: One sentence explaining what it is.35category: ui-components36type: component37difficulty: med38createdAt: 2026-06-1239updatedAt: 2026-06-1240---41```4243### Recommended frontmatter4445Add `tags`, `tech`, `targets`, `collections`, `labRoute`, `license`, and `author` for discoverability.4647## Category ↔ type pairs4849| Category | Type | Use for |50| --- | --- | --- |51| `ui-components` | `component` | Buttons, forms, cards, widgets |52| `components` | `component` | React-oriented reusable blocks |53| `pages` | `page` | Full page layouts → see [`page-resources`](../page-resources/SKILL.md) |54| `web-animations` | `animation` | Motion, scroll, canvas, WebGL |55| `patterns` | `pattern` | UX interaction patterns |56| `prompts` | `prompt` | AI prompt templates |57| `skills` | `skill` | Agent skill definitions |58| `database-schemas` | `schema` | SQL / ERD resources |59| `recommendations` | `recommendation` | Tool comparison topics (no code, no Lab) |6061Do not invent new category/type values without updating the schema (see [`add-collection`](../add-collection/SKILL.md) for the wiring list).6263## Snippet targets6465| Target | File |66| --- | --- |67| `html` | `snippets/html.html` |68| `react` | `snippets/react.tsx` |69| `next` | `snippets/next.tsx` |70| `vue` | `snippets/vue.vue` |71| `svelte` | `snippets/svelte.svelte` |72| `astro` | `snippets/astro.astro` |73| `typescript` | `snippets/typescript.ts` |74| `sql` | `snippets/schema.sql`, `seed.sql`, `queries.sql` |75| `markdown` | `snippets/markdown.md` |7677Only declare `targets` you actually ship.7879## Lab demos8081Set `labRoute: /<category>/<slug>` and provide `html.html` (+ linked `style.css` / `script.js`). Lab inlines assets at build time in `apps/lab`.8283## Post-change commands8485```bash86bun run --filter @stealthis/mcp catalog87bun run lint88bun run build:www89bun run build:lab # if labRoute set90bun run build:mcp # if metadata affects MCP tools91```9293## Schema alignment9495If you add fields or enum values, update in the same PR:9697- `packages/schema/src/schema.ts`98- `packages/schema/src/types.ts`99- `apps/www/src/content/config.ts`100- `apps/www/src/i18n/index.ts` (labels/filters)101102## Checklist103104- [ ] Folder `packages/content/resources/<slug>/`105- [ ] Valid frontmatter (Zod schema passes)106- [ ] Snippet files match `targets`107- [ ] MDX body documents usage108- [ ] MCP catalog regenerated109- [ ] Lint + relevant builds pass