Open eduardoarandah opened 3 years ago
Issue also reported on https://github.com/tomtom/tcomment_vim/issues/284
If you're here with same issue, you can use non-treesitter syntax with:
if (has("nvim"))
" Treesitter
Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'} " We recommend updating the parsers on update
endif
" also install Vue syntax
Plug 'posva/vim-vue', { 'for': ['vue' ] }
and later, add disable to vue
" treesitter enable
if (has("nvim"))
lua <<EOF
require'nvim-treesitter.configs'.setup {
ensure_installed ={ "javascript", "json", "css", .... here others.... }, -- one of "all", "maintained" (parsers with maintainers), or a list of languages
highlight = {
enable = true,
disable = { "vue" }
},
indent = {
enable = false
},
}
EOF
endif
Hi, I don't quite understand what's the issue here. Can you use the playground to reproduce the issue? And if it's reproducible there, can you post your input as text and the desired output? As a side note, tree-sitter-vue is a parser that only parses the vue-specific parts, the embedded parts are not parsed here, e.g., the content in <script>
/<style>
and the js expression/statement in the <template>
section.
Comments aren't working fine with treesitter with comment plugins
I'm not sure if this is an issue to be reported here or in https://github.com/tomtom/tcomment_vim so I'll post in both sites
neovim + treesitter commenting the same in html, js
Debug info:
:echo tcomment#debug#CollectInfo()
on template section:
on js section:
vim + polyglot works fine!
on template part:
on js part: