Skip to content

deps: upgrade typescript to 7 in every package - #1060

Closed
Aymericr wants to merge 1 commit into
mainfrom
cursor/deps-typescript-7-6cd4
Closed

Aymericr wants to merge 1 commit into
mainfrom
cursor/deps-typescript-7-6cd4

Conversation

@Aymericr

Copy link
Copy Markdown
Contributor

What does this PR do?

Moves the root and every package from typescript 6.0.3 to 7.0.2. The two apps were already on 7.0.2. Major upgrade, so no auto-merge.

Breaking changes (announcement)

  • TypeScript 7 is the native (Go) compiler and ships no programmatic API. import ts from 'typescript' now resolves to a version stub. A new API is expected in 7.1. Microsoft's recommended bridge is @typescript/typescript6, which re-exports the 6.0 API (and provides a tsc6 binary).
  • 6.0 deprecations become hard errors: target: es5, moduleResolution: node/node10/classic, baseUrl, and alwaysStrict: false. New defaults include strict: true. Our tsconfigs already pass under 6.0's rules, so nothing changed here.
  • Template-literal string inference now counts code points instead of UTF-16 units.

Code changes

  • packages/core/src/contracts/metadata-scan.ts (a test-only contract scanner) and scripts/fix-node-esm-imports.ts (a build step) use the compiler API. They now import it from @typescript/typescript6 (6.0.2), added as a devDependency to the root and to core.
  • packages/eslint-config stays on typescript 6.0.3: typescript-eslint needs the JS API and its peer range is >=4.8.4 <6.1.0.
  • @typescript/native-preview (used by the tsgo scripts) is untouched; swapping tsgo for tsc is left for a follow-up.

How to test

  1. bun install
  2. bun run ci. Expect check-types and build to run on the TS 7 tsc, and the reference-inventory contract tests to pass on the 6.0 API.

Screenshots / screen recording

N/A — non-visual change

Checklist

  • I've tested this locally with bun dev
  • My code follows the existing code style (run bun check to verify)
  • I've updated relevant documentation (if applicable)
  • This PR targets the main branch

Local results: check, skills:validate, check-types and build pass. turbo run test --continue shows only the 24 local-only failures that a clean main checkout also has in this environment (on GitHub, CI for main is green), and none are new.

Open in Web Open in Cursor 

TypeScript 7 ships no compiler API, so the metadata contract scanner and the
ESM import fixer read the 6.0 API from @typescript/typescript6, and the
ESLint config keeps typescript 6 for typescript-eslint.
Aymericr added a commit that referenced this pull request Oct 14, 2026
…1071)

typescript 7, @types/node 26, nanoid 6 (Node 22+), motion 14,
eslint-plugin-react-hooks 7, eslint 10 with @eslint/js 10, globals 17,
pdfkit 0.20 and react-grab 0.2, with one regenerated lockfile.

The root typescript is aliased to @typescript/typescript6 so hoisted
typescript-eslint keeps the 6.0 API it requires; every workspace
compiles with its own typescript 7.

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
@Aymericr

Copy link
Copy Markdown
Contributor Author

Landed in #1071 (dc65ba0), which combined the nine major upgrades with one lockfile. Closing as superseded. #1061 stays open.

@Aymericr Aymericr closed this Oct 15, 2026
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 this pull request may close these issues.

2 participants