Markdown grammar for tree-sitter
Maintained. Last release 5 weeks ago, commits in 2 of the last 26 weeks. Weaker on commit activity and release cadence.
pip install tree-sitter-markdowntree-sitter-markdown
A Markdown parser for tree-sitter.

The parser is designed to read markdown according to the CommonMark Spec, but some extensions to the spec from different sources such as Github flavored markdown are also included. These can be toggled on or off at compile time. For specifics see Extensions
Goals
Even though this parser has existed for some while and obvious issues are mostly solved, there are still lots of inaccuracies in the output. These stem from restricting a complex format such as markdown to the quite restricting tree-sitter parsing rules.
As such it is not recommended to use this parser where correctness is important. The main goal for this parser is to provide syntactical information for syntax highlighting in parsers such as neovim and helix.
Contributing
All contributions are welcome. For details refer to .