I'm having an issue with syntax highlighting for FastAPI decorators. In VSCode everything works perfectly out of the box (after installed some Python extensions), but in Neovim the whole decorator section has the same color (tried with a lot a color schemes)
Code looks like this in Neovim
Same code looks like this in VSCode:
This is my treesitter config:
{
'nvim-treesitter/nvim-treesitter',
build = ':TSUpdate',
main = 'nvim-treesitter.configs',
opts = {
ensure_installed = { 'python', 'bash', 'c', 'diff', 'html', 'lua', 'luadoc', 'markdown', 'markdown_inline', 'query', 'vim', 'vimdoc' },
auto_install = true,
highlight = {
enable = true,
additional_vim_regex_highlighting = { 'ruby' },
},
indent = { enable = true, disable = { 'ruby' } },
},
},
I'm using Neovim 0.10.0, and this config based on kickstart.nvim.
I tried disabling other plugins but this is not solved my issue. If I disable treesitter for this buffer, the highlighting works as I expected.