Snippets collection policy for lightweight practical notes
Decision
- Place lightweight practical notes (command fragments, minimal procedures, short config examples) in
snippets. - Operate with three content types: timeline posts in
blog, knowledge/definitions inglossary, and practical fragments insnippets. - Add the
snippetscollection and implement index/detail routes at/snippetsand/{lang}/snippets. - Keep
_template.ja.mdin the collection and exclude_-prefixed files from publication.
Context
The current content model had no clear home for short practical notes:
- Too thin for a blog post
- Not a definition page for glossary
Mixing these into blog blurs list intent and search intent.
At the same time, glossary is definition-oriented and does not fit command-centric snippets.
Options
- Option A: Keep short practical notes in
blog. - Option B: Put them under
glossary. - Option C: Add a dedicated
snippetscollection (chosen).
Rationale
- Readers get clearer entry points: posts, knowledge, and practical snippets.
- Isolating short notes helps preserve the quality bar of
blogarticles. - URL separation improves clarity of page intent for search engines.
Consequences
- Add a
snippetscollection schema insrc/content.config.ts. - Add
src/features/snippets/*,src/pages/snippets/*, andsrc/pages/[lang]/snippets*. - Add
snippetslabels to header navigation and i18n dictionaries. - Migrate the first content item (
avifencbatch conversion memo) intocontent/snippets/.
hsb.horse