Closed ivanbanov closed 2 years ago
Hi, I was wondering which path should I take to have eslint equivalent for StandardJS https://github.com/standard/vscode-standard.
Would you mind guiding me through it?
Hi, @ivanbanov I wrote an article about linting and formatting JavaScript using ESLint and Standard here. I hope it's what you're looking for.
I hope that answers the initial question.
I'll just comment on this part in the article:
First, in my case, it makes Sublime Text freezing when formatting is in process. Using command line to format code is much faster.
Adding this to LSP.sublime-settings
:
"lsp_code_actions_on_save": {
"source.fixAll.eslint": true,
},
should not cause any freezes as all that formatting happens on an async thread. How did you enable formatting exactly that you saw ST freezing?
I hope that answers the initial question.
I'll just comment on this part in the article:
First, in my case, it makes Sublime Text freezing when formatting is in process. Using command line to format code is much faster.
Adding this to
LSP.sublime-settings
:"lsp_code_actions_on_save": { "source.fixAll.eslint": true, },
should not cause any freezes as all that formatting happens on an async thread. How did you enable formatting exactly that you saw ST freezing?
Hi @rchl I wrote that article when I was using Sublime Text 3 and I forgot how exactly it got freeze 😅.
As long as I can remember, I was using SublimeJSPrettier as instructed in prettier-standard documentation in readme.
And I can confirm that in ST4 works without problem using your solution
"lsp_code_actions_on_save": {
"source.fixAll.eslint": true,
},
EDIT
I have updated my article with new technique using eslint-config-prettier-standard
and confirming that lsp-eslint
in Sublime Text 4 with proper configuration has no freezing issue when formatting.
Hi, I was wondering which path should I take to have eslint equivalent for StandardJS https://github.com/standard/vscode-standard.
Would you mind guiding me through it?