caw.vim icon indicating copy to clipboard operation
caw.vim copied to clipboard

Comments in vue file inconsistent after first template element

Open dyllandry opened this issue 5 years ago • 1 comments

This is a cool plugin, and I'll be absolutely jazzed if I'm able to use it correctly at work.

I think I've found a bug where the style of comments change from <!-- --> to /* */ after the first <template> element closes in a vue file. I've got context_filepath.vim installed. Here's an example:

<template>
  <div>
    <!-- <div>Test 1</div> -->
    <template>
      <!-- <div>Test 2</div> -->
    </template>
    /* <div>Test 3</div> */
  </div>
</template>

<script>
export default {}
</script>

<style>
</style>

I imagine this could be a problem with https://github.com/Shougo/context_filetype.vim/tree/master/doc but i have no idea how to diagnose that.

dyllandry avatar Sep 28 '20 19:09 dyllandry

for me it's the inverse, it work well in the template tag but not with the script or style tag :( ~~i tried this plugin because i thought it would work with vue file, but no, so i'll continue to use nerdcommenter since this plugins doesn't have anything more ?~~

edit : check this plugin suy/vim-context-commentstring which change 'commentstring' depending on your location in the file. it work well with caw.vim and vim-commentary, but didn't work with nerdcommenter for me.

mirsella avatar Oct 06 '20 07:10 mirsella