{"id":25611,"library":"fumadocs-transpiler","title":"Fumadocs Transpiler","description":"A Node.js CLI and library (v1.3.0) that converts annotated Markdown files into Fumadocs-compatible React/MDX components. Uses triple-colon (`:::`) annotation syntax for built-in components like callouts, tabs, steps, accordions, code blocks, files, and banners. Supports bidirectional conversion (Markdown ↔ MDX), watch mode, dry run, title/frontmatter auto-extraction, and custom component mappings. Requires Node >=16.0.0. Maintained by a single contributor; release cadence is irregular.","status":"active","version":"1.3.0","language":"javascript","source_language":"en","source_url":"https://github.com/jagjeevanak/fumadocs-transpiler","tags":["javascript","markdown","transpiler","fumadocs","react","documentation","cli","mdx","annotations","typescript"],"install":[{"cmd":"npm install fumadocs-transpiler","lang":"bash","label":"npm"},{"cmd":"yarn add fumadocs-transpiler","lang":"bash","label":"yarn"},{"cmd":"pnpm add fumadocs-transpiler","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Generated output is React components; runtime dependency for rendering.","package":"react","optional":true}],"imports":[{"note":"ESM-only since v1. No default export; use named import.","wrong":"const transpile = require('fumadocs-transpiler')","symbol":"transpile","correct":"import { transpile } from 'fumadocs-transpiler'"},{"note":"Use named import, not default.","wrong":"import transpileFile from 'fumadocs-transpiler'","symbol":"transpileFile","correct":"import { transpileFile } from 'fumadocs-transpiler'"},{"note":"Reverse conversion from MDX to annotated Markdown. ESM only.","wrong":"const { reverseTranspile } = require('fumadocs-transpiler')","symbol":"reverseTranspile","correct":"import { reverseTranspile } from 'fumadocs-transpiler'"}],"quickstart":{"code":"import { transpile } from 'fumadocs-transpiler';\n\nconst result = transpile(`\n---\ntitle: Example\n---\n:::callout{type=\"info\"}\nThis is an info callout.\n:::\n`, {\n  components: {\n    callout: true,\n    tabs: false\n  }\n});\n\nconsole.log(result);\n// Output: React component source code","lang":"typescript","description":"Shows ESM import and basic transpilation of a Markdown string with a callout annotation."},"warnings":[{"fix":"Use import instead of require(). Ensure package.json has \"type\": \"module\" or use .mjs extension.","message":"v1.0.0 removed CommonJS support; migration to ESM only.","severity":"breaking","affected_versions":">=1.0.0"},{"fix":"Use exact syntax ':::callout{type=\"info\"}' without spaces after colons.","message":"Triple-colon syntax must not have leading/trailing spaces after colons; e.g., '::: callout' is invalid.","severity":"gotcha","affected_versions":">=0.1.0"},{"fix":"Add 'description: ...' directly in the Markdown frontmatter instead of CLI flag.","message":"The --description CLI flag is deprecated in v1.3.0; use frontmatter YAML instead.","severity":"deprecated","affected_versions":">=1.3.0"},{"fix":"Set 'extractTitle: false' in options to preserve the heading.","message":"Auto title extraction removes the first # heading from output; if you need to keep the heading, disable extraction.","severity":"gotcha","affected_versions":">=0.5.0"},{"fix":"Use --extension .mdx CLI flag to override, or update import statements in generated files.","message":"Version 0.9.0 changed default output extension from .mdx to .tsx. Existing workflows may break.","severity":"breaking","affected_versions":">=0.9.0"},{"fix":"Preview with --dry-run before applying reverse; manual adjustments may be needed.","message":"Reverse transpilation does not support all Fumadocs features; complex MDX may fail.","severity":"gotcha","affected_versions":">=1.0.0"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Run 'npm install fumadocs-transpiler' in your project directory.","cause":"Missing local install or incorrect import path.","error":"Error: Cannot find module 'fumadocs-transpiler'"},{"fix":"Use ':::callout{type=\"info\"}' without spaces after colons.","cause":"Invalid annotation syntax, e.g., '::: callout' instead of ':::callout'.","error":"SyntaxError: Unexpected identifier 'callout'"},{"fix":"Use import { transpile } from 'fumadocs-transpiler'.","cause":"Default import used instead of named import.","error":"TypeError: transpile is not a function"},{"fix":"Verify the directory exists and path is correct; use absolute paths if unsure.","cause":"Specified input path is incorrect.","error":"Error: Input directory does not exist: ./docs"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}