Skip to content

Conversation

kkanden
Copy link

@kkanden kkanden commented Apr 28, 2025

hi,
i have implemented math detection using treesitter. there are still zone detections that rely on vimtex which i'm not sure could be so easily replaced with treesitter (eg. treesitter doesn't report the name of the math environment you're in). from my testing everything related to math detection works fine, including in markdown (and most likely any markdown superset).

credit goes to this comment.

cheers :)

@evesdropper
Copy link
Owner

super sorry I haven't gotten to this in a while, got sick and have been busy with various things.

I should have more time to test things this coming week and maybe some of the next week. I'm assuming things work except for the issue mentioned in #16, which I'll take a look at as well

@jacobinu
Copy link

This code works, but I realized that using the tree sitter breaks other things, the biggest being math object selection (lervag/vimtex#3111 (comment)). I think most people would be best served with tree sitter disabled.

@evesdropper
Copy link
Owner

returning from the void as I saw this comment

not sure if i implemented it already but i'd probably set treesitter as an option, and i'd also assume people use treesitter xor vimtex, so if treesitter is enabled, no vimtex features would break

i do agree that vimtex is probably the faster way to implement things, but a good number of people also use treesitter so it can be good to provide that option as well

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants