tree-sitter-grammars / tree-sitter-markdown

Markdown grammar for tree-sitter
MIT License
374 stars 45 forks source link

`wiki_link` is in highlights.scm but doesn't appear to be compiled in? #118

Open SergioBenitez opened 9 months ago

SergioBenitez commented 9 months ago

Hello!

I'm attempting to use this parser/grammar directly in a project. I'm getting an error when loading the highlights query due to an undeclared wiki_links node. It seems to me that the provided highlights.scm for the inline parser defines a capture for the node type, but the provided compiled parser and scanner don't actually define the node type. Am I understanding correctly?

If so, would it possible to have these two match, either by removing the wiki_link highlight or having the provided compiled artifacts be compiled with wiki_link?

Thank you!

MDeiml commented 8 months ago

You are correct. You can fix this either by removing the 'wiki_linkparts from your.scm` file or by enabling the wiki-link extension.

Editing the .scm file is the easier solution. At the moment these extensions do not really play nicely with any editors. See the README for more info, or #120 for how to maybe do this for neovim.