Created
October 12, 2016 16:22
-
-
Save madox2/235f23d6dbe052b60bef658095a1c2d9 to your computer and use it in GitHub Desktop.
Function which runs eslint --fix and saves the buffer. It is mapped to :W command
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function ESLintFix() | |
write | |
silent execute "!./node_modules/.bin/eslint --fix %" | |
edit! % | |
redraw! | |
endfunction | |
command W call ESLintFix() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment