All activity
Daniel Marquesleft a comment
Hey everyone! I'm the maker of mdshape. I kept running into the same problem: Markdown is everywhere — docs, runbooks, AI prompts, PDF exports — but extracting structured data from it always meant regex spaghetti or fragile AST walkers. So I built mdshape: you define a schema describing the Markdown structure you expect, call .safeParse(markdown), and get typed JSON back. If something's wrong,...

markschemaMarkdown in, typed JSON out — no regex, no AST glue code
mdshape is a schema-first library that turns any Markdown file into typed JSON with a single function call.
Instead of writing regex, chaining remark plugins, or walking ASTs manually, you define a schema — headings, sections, fields, tables, code blocks — and mdshape parses and validates everything for you. Errors come back with line numbers, paths, and codes.
27 typed builders for tables, Mermaid diagrams, LaTeX math, images, links, and more. Full TypeScript inference from schema to json.

markschemaMarkdown in, typed JSON out — no regex, no AST glue code



