Open davidatsurge opened 2 years ago
That is a great idea. Although I’m not familiar with that area of treesitter (will need to learn). It will take some time but if it makes life easier for people, I’ll try to implement it.
I’m curious, how would you / other people you use such a feature?
First off, thanks a bunch for working on this plugin! I absolutely love the possibilities that neovim's treesitter integration opens up, and it's great when you find a plugin that you were thinking that you'd have to code yourself 😂.
Soo, the
nvim-treesitter-textobjects
plugin has a set of cross-filetype definitions for textobjects/move targets, as summarized here. I was wondering if you'd be interested in allowing syntax-tree-surfer to use these definitions (like@function.outer
, .. etc) to define jump targets. I know that syntax-tree-surfer also has other features like swapping and moving, and I don't see anything that prevents these definitions being used there as well, but I am really interested in jumping (like here ).The advantage of using the definitions from
nvim-treesitter-textobjects
is that we build upon the work did there to define a consistent definition of a function/ a class/an if statement/..etc across many files.