Skip to content

Peer dependency for @typescript-eslint/parser@^7.0.0 #16

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

Open
kjetilkh-politiet opened this issue Feb 15, 2024 · 3 comments
Open

Peer dependency for @typescript-eslint/parser@^7.0.0 #16

kjetilkh-politiet opened this issue Feb 15, 2024 · 3 comments

Comments

@kjetilkh-politiet
Copy link

Hi, is it possible to add peer dependency for @typescript-eslint/parser@^7.0.0?

JH1ller added a commit to JH1ller/eslint-plugin-jsx-expressions that referenced this issue Mar 27, 2024
@karlhorky
Copy link
Contributor

karlhorky commented May 20, 2024

To be clear, this is causing errors like this while linting, if the ESLint config uses a v7+ version of the typescript-eslint packages:

$ yarn eslint . --max-warnings 0
$ /home/runner/work/courses/courses/node_modules/.bin/eslint . --max-warnings 0
(node:2195) ExperimentalWarning: Importing JSON modules is an experimental feature and might change at any time
(Use `node --trace-warnings ...` to show where the warning was created)
Oops! Something went wrong! :(
ESLint: 9.0.0
Error: Error while loading rule 'jsx-expressions/strict-logical-expressions': 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.
Occurred while linting /home/runner/work/courses/courses/eslint.config.js
    at Object.getParserServices (/home/runner/work/courses/courses/node_modules/@typescript-eslint/utils/dist/eslint-utils/getParserServices.js:21:15)
    at create (/home/runner/work/courses/courses/node_modules/eslint-plugin-jsx-expressions/dist/rules/strict-logical-expressions.js:60:52)
    at Object.create (/home/runner/work/courses/courses/node_modules/@typescript-eslint/utils/dist/eslint-utils/RuleCreator.js:38:20)
    at createRuleListeners (/home/runner/work/courses/courses/node_modules/eslint/lib/linter/linter.js:1003:21)
    at /home/runner/work/courses/courses/node_modules/eslint/lib/linter/linter.js:1129:84
    at Array.forEach (<anonymous>)
    at runRules (/home/runner/work/courses/courses/node_modules/eslint/lib/linter/linter.js:1061:34)
    at Linter._verifyWithFlatConfigArrayAndWithoutProcessors (/home/runner/work/courses/courses/node_modules/eslint/lib/linter/linter.js:1910:31)
    at Linter._verifyWithFlatConfigArray (/home/runner/work/courses/courses/node_modules/eslint/lib/linter/linter.js:2046:21)
    at Linter.verify (/home/runner/work/courses/courses/node_modules/eslint/lib/linter/linter.js:1535:61)

sleeyax added a commit to sleeyax/eslint-plugin-jsx-expressions that referenced this issue May 30, 2024
@karlhorky
Copy link
Contributor

typescript-eslint v8 was released on 31 July 2024:

So it would probably be good to update to v8 instead of v7.

@Djontleman
Copy link

Is anyone having this problem for ESLint 8? I've attempted upgrading our monorepo which is using [email protected] to [email protected] and have not encountered any problems that would prevent the upgrade.

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

Successfully merging a pull request may close this issue.

3 participants