Skip to content

TypeScript 7.0.2 Support #12518

Description

@IshtarStar

Before You File a Bug Report Please Confirm You Have Done The Following...

  • I have tried restarting my IDE and the issue persists.
  • I have updated to the latest version of the packages.
  • I have searched for related issues and found none that matched my issue.
  • I have read the FAQ and my problem is not listed.
  • If I used AI assistance to prepare this issue, I have reviewed and followed the AI Contribution Policy.

Issue Description

Relevant Package

typescript-eslint / @typescript-eslint/typescript-estree

Description

I tried upgrading a Vite React TypeScript project from TypeScript 6.0.3 to TypeScript 7.0.2.

With typescript-eslint@8.63.0, installation via npm ci fails because the published peer dependency range only allows TypeScript <6.1.0.

If dependencies are installed with npm install, ESLint then crashes inside @typescript-eslint/typescript-estree.

I understand TypeScript 7 may not be officially supported yet. I am filing this as a TypeScript 7 support report / compatibility tracking data point.

Versions

  • Node: 24.13.0
  • npm: 11.6.2
  • OS: macOS Darwin arm64
  • eslint: 10.6.0
  • typescript-eslint: 8.63.0
  • typescript: 7.0.2
  • vite: 8.1.3

package.json relevant devDependencies

{
  "devDependencies": {
    "eslint": "^10.6.0",
    "typescript": "^7.0.2",
    "typescript-eslint": "^8.63.0",
    "vite": "^8.1.3"
  }
}

Reproduction Steps

  1. Set TypeScript to ^7.0.2
  2. Run:
npm install
npm ci
npm run lint

Actual Result

npm ci fails with:

npm error ERESOLVE could not resolve

While resolving: typescript-eslint@8.63.0
Found: typescript@7.0.2

Could not resolve dependency:
peer typescript@">=4.8.4 <6.1.0" from typescript-eslint@8.63.0

If installed via npm install, linting fails with:

ESLint: 10.6.0

TypeError: Cannot read properties of undefined (reading 'Cjs')
    at .../node_modules/typescript-eslint/node_modules/@typescript-eslint/typescript-estree/dist/create-program/shared.js

Expected Result

Either:

  • TypeScript 7 is supported by typescript-eslint, or
  • TypeScript 7 unsupported usage fails with a clear compatibility warning/error instead of an internal crash.

Additional Context

npm run build succeeds with TypeScript 7.0.2 in this project, but npm ci and npm run lint fail.

Reproduction Repository Link

https://github.com/IshtarStar/typescript-eslint-typescript-7-repro

Repro Steps

  1. Clone the reproduction repository:
   git clone https://github.com/IshtarStar/typescript-eslint-typescript-7-repro.git
   cd typescript-eslint-typescript-7-repro
  1. Reproduce the install failure:
npm ci

This fails because typescript-eslint@8.63.0 has a peer dependency range of typescript >=4.8.4 <6.1.0, while the project uses typescript@7.0.2.
3. Reproduce the ESLint crash after forcing installation:

npm run versions
npm run lint
  1. Observe the ESLint crash:
TypeError: Cannot read properties of undefined (reading 'Cjs')
    at .../@typescript-eslint/typescript-estree/dist/create-program/shared.js:59:18

The repository also includes a GitHub Actions workflow with two jobs that reproduce both cases automatically:

  • npm ci peer dependency conflict
  • ESLint crash after npm install

Versions

package version
@typescript-eslint/eslint-plugin 8.63.0
@typescript-eslint/parser 8.63.0
@typescript-eslint/scope-manager 8.63.0
@typescript-eslint/typescript-estree 8.63.0
@typescript-eslint/type-utils 8.63.0
@typescript-eslint/utils 8.63.0
TypeScript 7.0.2
ESLint 10.6.0
node 24.18.0
npm 11.16.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingduplicateThis issue or pull request already exists

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions