@ori-ori/parser
v0.1.0
Published
Markdown / frontmatter / section parsing for ori
Downloads
378
Readme
@ori-ori/parser
Markdown / frontmatter / section parsing for the ori toolchain.
Exports
parseFrontmatter(raw)— splits gray-matter style frontmatter from bodyextractSections(markdown)— extracts H2/H3 sections, recognising Pandoc-style{#id}anchorshashSection(content)/normalizeForHash(content)— deterministic content hashing for change detectionOriFrontmatterSchema— zod schema for the ori-specificcoherence:andori:frontmatter blocks
Section IDs use the ## Heading text {#kebab-case-id} convention. When an anchor is missing the parser still returns a Section but its id is null and an auto-generated key _h{depth}_{n} is used in byId.
