3 homepage: https://github.com/prettier/vim-prettier
5 vim-prettier adds Prettier support for Vim.
8 ## Updating `vim-prettier`
16 > `vim-prettier` is a vim plugin wrapper for prettier, pre-configured with
17 > custom default prettier settings.
19 You'll also need `ALE`, [`syntastic`](https://webinstall.dev/vim-syntastic), or
22 ### How to install by hand
25 git clone --depth=1 https://github.com/prettier/vim-prettier ~/.vim/pack/plugins/start/vim-prettier
28 ### How to configure your `.vimrc`
31 " don't check syntax immediately on open or on quit
32 let g:syntastic_check_on_open = 1
33 let g:syntastic_check_on_wq = 0
35 " we also want to get rid of accidental trailing whitespace on save
36 autocmd BufWritePre * :%s/\s\+$//e
40 """""""""""""""""""""""""""
41 " Prettier-specific options "
42 """""""""""""""""""""""""""
44 " format as-you-type is quite annoying, so we turn it off
45 let g:prettier#autoformat = 0
47 " list all of the extensions for which prettier should run
48 autocmd BufWritePre .babelrc,.eslintrc,.jshintrc,*.js,*.jsx,*.mjs,*.ts,*.tsx,*.css,*.less,*.scss,*.json,*.graphql,*.md,*.vue,*.yaml,*.html PrettierAsync
51 ### How to install Prettier
62 npm install -g prettier@2