You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Even though prettier.eslintIntegration is enabled, eslint -fix is not applied but only prettier is applied.
I think most issues related with vue are in the same situation.
After a lot of digging, I finaly found out what caused this issue.
How this issue occured
vue project is created with vue cli
The default parser option for eslint is configured as below
prettier-vscode format the vue file with eslintintegration
prettier-vscode call bundled eslint-prettier
bundled eslint-prettier call bundled vue-eslint-parser regardless of user's settings
bundled vue-eslint-parser can't resolve babel-eslint in parserOptions.parser because babel-eslint is not bundled with prettier-vscode and eslint-prettier
eslint -fix stop with the error, so only prettir is applied
solution
eslint-prettir should not overwritte the parser that user provided.
Fortunately the eslint-prettir problem is fixed by the latest release.
So the solution for prettier-vscode is to update eslint-prettir version to 9.0.0.
The text was updated successfully, but these errors were encountered:
Even though
prettier.eslintIntegration
is enabled,eslint -fix
is not applied but only prettier is applied.I think most issues related with vue are in the same situation.
After a lot of digging, I finaly found out what caused this issue.
How this issue occured
vue project is created with
vue cli
prettier-vscode
format the vue file with eslintintegrationprettier-vscode
call bundledeslint-prettier
eslint-prettier
call bundledvue-eslint-parser
regardless of user's settingsvue-eslint-parser
can't resolvebabel-eslint
inparserOptions.parser
becausebabel-eslint
is not bundled withprettier-vscode
andeslint-prettier
eslint -fix
stop with the error, so onlyprettir
is appliedsolution
eslint-prettir
should not overwritte the parser that user provided.Fortunately the
eslint-prettir
problem is fixed by the latest release.So the solution for
prettier-vscode
is to updateeslint-prettir
version to 9.0.0.The text was updated successfully, but these errors were encountered: