Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[13.0.0] Error: Error while loading rule '@typescript-eslint/consistent-type-imports': You have used a rule which requires parserServices to be generated #74

Open
frankykubo opened this issue Mar 27, 2024 · 1 comment

Comments

@frankykubo
Copy link

After update from "@vue/eslint-config-typescript": "^12.0.0", to "@vue/eslint-config-typescript": "^13.0.0",, the error has shown up:

Error: Error while loading rule '@typescript-eslint/consistent-type-imports': 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.
Parser: X:\WebTV Frontend\node_modules\.pnpm\vue-eslint-parser@9.4.2_eslint@8.57.0\node_modules\vue-eslint-parser\index.js
Note: detected a parser other than @typescript-eslint/parser. Make sure the parser is configured to forward "parserOptions.project" to @typescript-eslint/parser.
Occurred while linting X:\WebTV Frontend\src\components\player\video\info\LiveIndicator.vue
    at throwError (X:\WebTV Frontend\node_modules\.pnpm\@typescript-eslint+utils@7.4.0_eslint@8.57.0_typescript@5.4.3\node_modules\@typescript-eslint\utils\dist\eslint-utils\getParserServices.js:40:11)
    at getParserServices (X:\WebTV Frontend\node_modules\.pnpm\@typescript-eslint+utils@7.4.0_eslint@8.57.0_typescript@5.4.3\node_modules\@typescript-eslint\utils\dist\eslint-utils\getParserServices.js:20:9)
    at create (X:\WebTV Frontend\node_modules\.pnpm\@typescript-eslint+eslint-plugin@7.4.0_@typescript-eslint+parser@7.4.0_eslint@8.57.0_typescript@5.4.3\node_modules\@typescript-eslint\eslint-plugin\dist\rules\consistent-type-imports.js:85:68)
    at Object.create (X:\WebTV Frontend\node_modules\.pnpm\@typescript-eslint+utils@7.4.0_eslint@8.57.0_typescript@5.4.3\node_modules\@typescript-eslint\utils\dist\eslint-utils\RuleCreator.js:38:20)
    at createRuleListeners (X:\WebTV Frontend\node_modules\.pnpm\eslint@8.57.0\node_modules\eslint\lib\linter\linter.js:895:21)
    at X:\WebTV Frontend\node_modules\.pnpm\eslint@8.57.0\node_modules\eslint\lib\linter\linter.js:1066:110
    at Array.forEach (<anonymous>)
    at runRules (X:\WebTV Frontend\node_modules\.pnpm\eslint@8.57.0\node_modules\eslint\lib\linter\linter.js:1003:34)
    at Linter._verifyWithoutProcessors (X:\WebTV Frontend\node_modules\.pnpm\eslint@8.57.0\node_modules\eslint\lib\linter\linter.js:1355:31)
    at X:\WebTV Frontend\node_modules\.pnpm\eslint@8.57.0\node_modules\eslint\lib\linter\linter.js:1913:29
 ELIFECYCLE  Command failed with exit code 2

Any recommendations how should this be fixed?

@cuebit
Copy link
Member

cuebit commented Mar 28, 2024

I encountered this issue and traced it to @typescript-eslint/eslint-plugin@7.4.0 (see this blog post). For now, I've pinned it to 7.3.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants