RRethy / vim-illuminate

illuminate.vim - (Neo)Vim plugin for automatically highlighting other uses of the word under the cursor using either LSP, Tree-sitter, or regex matching.
2.19k stars 50 forks source link

How to disable vim-illuminate for only certain words ? #105

Closed Yolo390 closed 2 years ago

Yolo390 commented 2 years ago

Hi there,

it's not about a bug, just an how to do for newbie !

Is it possible to disable words like 'local' or 'function' for lua filetype ?

When I type :echo synIDattr(synID(line("."), col("."), 1), "name") under lua function keyword, nothing return...

Did I missed something ?

Thanks, Flo !

RRethy commented 2 years ago

If :echo synIDattr(synID(line("."), col("."), 1), "name") doesn't work then you are probably using tree-sitter which disables standard highlight and syn id. There's no way around that at the moment.

Yolo390 commented 2 years ago

Yep I use tree-sitter.

Thanks for your reply !