vim-prettier icon indicating copy to clipboard operation
vim-prettier copied to clipboard

Plugin deletes empty line at end of file without @format/@prettier tags

Open ridgekuhn opened this issue 4 years ago • 0 comments

Do you want to request a feature or report a bug? Bug

What is the current/expected behavior? It shouldn't delete the empty line at the end of the file if I'm not using the @format/@prettier tags and have not manually run it.

What version of vim-prettier are you using - (output of :PrettierVersion) ? 1.0.0-beta

What version of prettier are you using - (output of :PrettierCliVersion) ? 1.19.1

What is your prettier executable path - (output of :PrettierCliPath) ? */node_modules/.bin/prettier

Did this work in previous versions of vim-prettier and/or prettier ? Don't know

I'm using vim-pathogen, so I installed like so:

$ cd ~/.vim/bundle
$ git clone https://github.com/prettier/vim-prettier
$ cd vim-prettier
$ yarn install

Added this line to my ~/.vimrc:

let g:prettier#autoformat = 1

Then, in my NodeJS project directory:

$ yarn add -D prettier/vim-prettier

ridgekuhn avatar Sep 16 '20 03:09 ridgekuhn