JoosepAlviste/nvim-ts-context-commentstring

Vue comment not working properly

shy-robin opened this issue · 2 comments

Minimal reproducible full config

-- Your configuration here

Description

I found a weird issue. If a vue file contains a empty <style> block, commenting will not work properly. Like this:
image
You can see all the comments start with //.

If I remove the empty <style> block or write some styles in the block, it will work fine. Like this:
image
You can see the <style> block was removed, and the comments in <template> and <script> work fine.

image
When I write some styles in <style> block, it works also.

Steps to reproduce

See above

Expected behavior

See above

Actual behavior

See above

Additional context

No response

Hey! That's an interesting issue, I tried to reproduce it, but didn't manage to:

Screen.Recording.2023-10-15.at.18.22.33.mov

I'm using Comment.nvim as my commenting plugin, what are you using?

Could you also add a minimal config where the issue can be reproduced? The example here can be used as a base: https://github.com/JoosepAlviste/nvim-ts-context-commentstring/blob/main/utils/minimal_init.lua

@JoosepAlviste
Thanks for your reply.
I am not using Comment.nvim. I just use the comment feature which is provided by LazyVim and it uses mini.comment.
This is the document: https://www.lazyvim.org/plugins/coding#minicomment
image