vim-matchup icon indicating copy to clipboard operation
vim-matchup copied to clipboard

.njk (Nunjucks) support?

Open antgel opened this issue 2 years ago • 1 comments
trafficstars

Hi and thanks for this great plugin. I took the liberty of not filling in the template because I suspect the "bug" might be PBKAC. The plugin works great on *.html files, however when I load *.njk (Nunjucks) files, it doesn't load. Is this a bug or a feature, and if the latter, how do I enable the plugin?

I would be happy for the plugin to be active "only" on HTML tags for now, the Nunjucks {{ }} delimiters tend to be short hence the plugin is less relevant.

(Been using vi(m) for 30 years and only now am I starting to get to grips with Lua etc :man_facepalming: )

antgel avatar Jun 21 '23 13:06 antgel

You should be able to get something simple working via

au FileType nunjucks let b:match_words = matchup#util#standard_html()
au BufNewFile,BufRead *.njk setf nunjucks

In your config, although I didn't test it.

andymass avatar Jul 03 '23 13:07 andymass