Parsing Error: The file does not match your project config
-
Hi,
A few weeks ago I setup a Quasar project using the CLI, with typescript, using prettier (all chosen via the CLI).
Since then, I’ve had parsing errors, today I decided that it was enough and I should make them dissapear, but I can’t get it done. This is the errors that I get on every single .vue file when it is open (error is highlighted on first line).Parsing error: "parserOptions.project" has been set for @typescript-eslint/parser. The file does not match your project config: src\components\Folder\File.vue. The file must be included in at least one of the projects provided.
The config is the default one:
parserOptions: { // https://github.com/typescript-eslint/typescript-eslint/tree/master/packages/parser#configuration // https://github.com/TypeStrong/fork-ts-checker-webpack-plugin#eslint // Needed to make the parser take into account 'vue' files extraFileExtensions: ['.vue'], parser: '@typescript-eslint/parser', project: resolve(__dirname, './tsconfig.json'), tsconfigRootDir: __dirname, ecmaVersion: 2018, // Allows for the parsing of modern ECMAScript features sourceType: 'module' // Allows for the use of imports },
Does this mean that my project variable is not correct? I tried a few things and they all results with the error, except if I do not set the project, but that most likely results in something wrong for the linter, doesn’t it?
I don’t understand why the path src\components\Folder\File.vue is not included in the project?
Did anyone faced the same problem, and if so, how did you solve it?
Thanks! -
I’m having the same issue on a brand-new project on which I have yet to modify anything. Following the thread for updates.
Typescript support has been enabled from the beginning using the quasar cli during project initiliazation.Quasar version: 2.1.6
Node: v12.19.0 -
If you have issues with an
unmodified
Quasar projectcreated by
the QuasarCLI
, I would consider posting an Github issue. -
This post is deleted! -
Downgrade to Typescript version 3.8.3.
https://github.com/typescript-eslint/typescript-eslint/issues/2127