The Markdown Frontmatter Schema Analyzer is a Node.js script that recursively scans Markdown (.md and .mdx) files in a specified directory, extracts their frontmatter, and analyzes the data types of attributes within the frontmatter. The script provides a summary of consistent and conflicting schema data across all analyzed files, making it easier to identify discrepancies in metadata. This ultimately will help you build a json schema.
- Read Markdown Files: The script recursively traverses the specified directory and collects all Markdown files.
- Parse Front Matter: For each Markdown file, it reads the content and extracts the front matter using the
front-matter
library.