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
npm init vue@3
Vue.js - The Progressive JavaScript Framework
√ Project name: ... vue-project
√ Add TypeScript? ... Yes
√ Add JSX Support? ... No
√ Add Vue Router for Single Page Application development? ... Yes
√ Add Pinia for state management? ... No
√ Add Vitest for Unit Testing? ... Yes
√ Add Cypress for End-to-End testing? ... No
√ Add ESLint for code quality? ... Yes
√ Add Prettier for code formatting? ... No
What is expected?
There should be a config that allows rules such as "@typescript-eslint/no-unsafe-assignment": "error" to be configured. However, when this is configured, the following error is given:
You have used a rule which requires parserServices to be generated. You must therefore provide a value for the "parserOptions.project" property for @typescript-eslint/parser.
If you then provide this project value in .eslintrc.cjs:
There are many useful ESLint rules in that repo that I wish to enforce on my Vue TypeScript code, so it is a major problem that the default Vue site's config doesn't work with it. I'd like to know how to get it to work, and perhaps the default config should be changed to avoid using project references.
Yikes. That really reminds me why I had a good hard long look into using Blazor for my project instead of JS/TS/Vue. The latter still feels unfinished to the point of being buggy. Hopefully in a few years Blazor will be ready for primetime and I can just use C# from start to finish!
Vue version
3.2.38
Link to minimal reproduction
https://gitlab.com/jez9999/vue3-demo
Steps to reproduce
What is expected?
There should be a config that allows rules such as
"@typescript-eslint/no-unsafe-assignment": "error"
to be configured. However, when this is configured, the following error is given:If you then provide this project value in
.eslintrc.cjs
:... Vue's
.tsconfig
setup should work with this.What is actually happening?
Because Vue's
.tsconfig
setup is using project references, this does not work with typescript-eslint parser services. typescript-eslint does not yet support project references.There are many useful ESLint rules in that repo that I wish to enforce on my Vue TypeScript code, so it is a major problem that the default Vue site's config doesn't work with it. I'd like to know how to get it to work, and perhaps the default config should be changed to avoid using project references.
System Info
Any additional comments?
No response
The text was updated successfully, but these errors were encountered: