Vim: Toggle Comments (any language)

The easiest way is to get NERDCommenter:

Plug 'preservim/nerdcommenter'
:PlugInstall

and use <leader>c<space> to toggle comments.

By default <leader> is backspace (\).

Thanks! You can always email me or use contact form for more questions/comments etc.


vim

22 Words

2021-09-20