1

I recently switched to Neovim and I tried to configure native LSP with Treesitter.

I ran into some wrong highlighting with PHP combined with HTML. Everytime when I write php in html element, closing tag is not highlighted.

enter image description here

Treesitter cfg:

local configs = require'nvim-treesitter.configs'
configs.setup {
  ensure_installed = 'maintained', --Only use parsers that are maintained
  highlight = { -- enable highlighting
    enable = true,
  },
  indent = {
    enabled = true,
  },
}

I found something about multiple lang support for one file type with language injections but I have no idea how to implement that.

Dvandy
  • 41
  • 8

1 Answers1

1

Issue with neovim treesitter.

Issue: https://github.com/nvim-treesitter/nvim-treesitter/issues/2565

Dvandy
  • 41
  • 8