Comments (10)
Hi @adam-beck,
Thanks for reporting this issue will look into it
from vim-prettier.
It does the same thing with .json
files as well. The CLI works as expected.
vim-prettier
version: 0.2.4
prettier
version: 1.8.1
VIM - Vi IMproved 8.0 (2016 Sep 12, compiled Nov 6 2017 09:45:01)
Included patches: 1-1272
Compiled by adam@foobar
Huge version with GTK2 GUI. Features included (+) or not (-):
+acl +clipboard +dialog_con_gui +file_in_path +job +lua +mouse_sgr +path_extra +rightleft +tag_old_static +toolbar +windows
+arabic +cmdline_compl +diff +find_in_path +jumplist +menu -mouse_sysmouse +perl +ruby -tag_any_white +user_commands +writebackup
+autocmd +cmdline_hist +digraphs +float +keymap +mksession +mouse_urxvt +persistent_undo +scrollbind -tcl +vertsplit +X11
+balloon_eval +cmdline_info +dnd +folding +lambda +modify_fname +mouse_xterm +postscript +signs +termguicolors +virtualedit -xfontset
+browse +comments -ebcdic -footer +langmap +mouse +multi_byte +printer +smartindent +terminal +visual +xim
++builtin_terms +conceal +emacs_tags +fork() +libcall +mouseshape +multi_lang +profile +startuptime +terminfo +visualextra +xpm
+byte_offset +cryptv +eval +gettext +linebreak +mouse_dec -mzscheme -python +statusline +termresponse +viminfo +xsmp_interact
+channel +cscope +ex_extra -hangul_input +lispindent -mouse_gpm +netbeans_intg +python3 -sun_workshop +textobjects +vreplace +xterm_clipboard
+cindent +cursorbind +extra_search +iconv +listcmds -mouse_jsbterm +num64 +quickfix +syntax +timers +wildignore -xterm_save
+clientserver +cursorshape +farsi +insert_expand +localmap +mouse_netterm +packages +reltime +tag_binary +title +wildmenu
system vimrc file: "$VIM/vimrc"
user vimrc file: "$HOME/.vimrc"
2nd user vimrc file: "~/.vim/vimrc"
user exrc file: "$HOME/.exrc"
system gvimrc file: "$VIM/gvimrc"
user gvimrc file: "$HOME/.gvimrc"
2nd user gvimrc file: "~/.vim/gvimrc"
defaults file: "$VIMRUNTIME/defaults.vim"
system menu file: "$VIMRUNTIME/menu.vim"
fall-back for $VIM: "/usr/local/share/vim"
f-b for $VIMRUNTIME: "/usr/local/share/vim/vim80"
Compilation: gcc -c -I. -Iproto -DHAVE_CONFIG_H -DFEAT_GUI_GTK -pthread -I/usr/include/gtk-2.0 -I/usr/lib/x86_64-linux-gnu/gtk-2.0/include -I/usr/include/gio-unix-2.0/ -I/usr/include/cairo -I/usr/include/pango-
1.0 -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pixman-1 -I/usr/include/libpng16 -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/libpng16 -I/usr/include/pango-1.0 -I/usr/include/harfbuzz -I/usr/inclu
de/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -I/usr/include/freetype2 -g -O2 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1
Linking: gcc -L. -Wl,-Bsymbolic-functions -Wl,-z,relro -Wl,-z,now -fstack-protector -rdynamic -Wl,-export-dynamic -Wl,-E -L/usr/local/lib -Wl,--as-needed -o vim -lgtk-x11-2.0 -lgdk-x11-2.0 -lpangocairo-1.0
-latk-1.0 -lcairo -lgdk_pixbuf-2.0 -lgio-2.0 -lpangoft2-1.0 -lpango-1.0 -lgobject-2.0 -lglib-2.0 -lfontconfig -lfreetype -lSM -lICE -lXpm -lXt -lX11 -lXdmcp -lSM -lICE -lm -ltinfo -lnsl -lselinux -ldl -L/us
r/lib -llua5.1 -Wl,-E -fstack-protector-strong -L/usr/local/lib -L/usr/lib/x86_64-linux-gnu/perl/5.24/CORE -lperl -ldl -lm -lpthread -lcrypt -L/usr/lib/python3.5/config -lpython3.5m -lruby-2.3 -lpthread -lgm
p -ldl -lcrypt -lm
from vim-prettier.
Looks like something has changed on the new prettier 1.8
release. Will look into it and do a new release with the fixes as soon as possible
from vim-prettier.
Managed to reproduce this issue on prettier
1.8.1
will investigate a bit more on this tomorrow to try to solve it.
This seems to be only happening only on :PrettierAsync
, so in the mean time people can be unblocked by using the synchronous formatting :Prettier
from vim-prettier.
So it turns out this was a regression introduced by #74
At this stage reverted that PR and will revisit it again to make sure no regressions will be introduced
from vim-prettier.
I'm ok with the revert, but I have no idea why the PR could cause this bug.
from vim-prettier.
If you're using nvm like me, and forget to set a node version in the terminal you launch vim from -- this can happen as well. Just heads up :)
from vim-prettier.
I've almost given up on coc-prettier because of this, there seems to be no solution for this. Such a shame
from vim-prettier.
@stevematdavies can you please open a new issue tracking this and Iām happy to revisit it
from vim-prettier.
Thanks for the offer, but due to time constraints, I have chosen an alternative. However, once I have the time, I will certainly open a new issue.
from vim-prettier.
Related Issues (20)
- feature request to disable automatic mappings set by the plugin
- .eslintrc is ignored
- prettier hang on formatting a bigger file
- MacOS Monterey M1 plugin not loaded
- When endOfLine option set to 'crlf', ^M appear at the end of each line
- Prettier: failed to parse buffer ā on mixed HTML/PHP file HOT 1
- Formatting on save stop when saving again
- Deletes comments in Ruby files HOT 3
- The same prettier doesn't work correctly on WSL
- plugin didn't work without installing eslint-config-prettier & eslint-plugin-prettier
- Request: check for filetype javascript (not just the .js and .jsx extensions) HOT 1
- Prettier auto format on Save not working. HOT 1
- Why prettier keeps adding warn messages on top of my document? HOT 16
- Deprecated / Unknown options when using Prettier v3 HOT 3
- Keep show warning after save! HOT 1
- Error while resolving package dependencies HOT 3
- Error on manual trigger
- prettier runs with incorrect prettier configuration HOT 2
- Vim-Prettier is using its own defaults, not the defaults from prettier (in my case, trailingComma)
- `Failed to parse buffers` for Ruby files. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
š Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ššš
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ā¤ļø Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vim-prettier.