Using stylefmt like echo "invalid-css" | stylefmt results in a an empty output with zero exit code. stylefmt should emit a best effort format or just the invalid css. This would be in line with other formatters and stylefmt could be integrated in vim-autoformat. Currently vim-stylefmt is unusable because of this too.
I am using a cumbersome workaround in my vimrc to get around this:
let g:formatdef_stylefmt = '"cat > .tmp_stylefmt && stylefmt .tmp_stylefmt && cat .tmp_stylefmt && rm .tmp_stylefmt"'
let g:formatters_css = ['stylefmt']
Using
stylefmt
likeecho "invalid-css" | stylefmt
results in a an empty output with zero exit code.stylefmt
should emit a best effort format or just the invalid css. This would be in line with other formatters and stylefmt could be integrated in vim-autoformat. Currently vim-stylefmt is unusable because of this too.I am using a cumbersome workaround in my vimrc to get around this: