unstale

npm / typescript

typescript

What changed in typescript 6 to 7, from its official release notes, upgrade guides and advisories. Also covers @typescript/typescript6. Sources checked 2026-10-18.

33 breaking5 deprecations11 new APIs and options2 performance8 behavior and defaults2 tooling1 fixes and other

See which of these apply to your code, ranked, in your agent:

npx @unstale/cli init

@unstale/cli on npm

typescript 731 changes

Breaking changes 19

  • The asserts keyword is no longer allowed on imports; use with instead to align with import-attribute syntax.

    7.0.2release notes

  • allowSyntheticDefaultImports can no longer be set to false.

    6.0.2, 7.0.2release notesrelease notes

  • alwaysStrict is assumed to be true and can no longer be set to false.

    7.0.2release notes

  • baseUrl is no longer supported; paths can instead be made relative to the project root.

    7.0.2release notes

  • downlevelIteration is no longer supported and now produces a hard error.

    7.0.2release notes

  • esModuleInterop can no longer be set to false.

    6.0.2, 7.0.2release notesrelease notes

  • module now defaults to esnext.

    7.0.2release notes

  • The amd, umd, systemjs, and none module modes are no longer supported; esnext or preserve are recommended with bundlers or browser-based resolution.

    7.0.2release notes

  • The classic module-resolution mode is no longer supported; bundler or nodenext are recommended.

    6.0.2, 7.0.2release notesrelease notes

  • The node and node10 module-resolution modes are no longer supported; nodenext or bundler are recommended.

    7.0.2release notes

  • noUncheckedSideEffectImports now defaults to true.

    6.0.2, 7.0.2release notesrelease notes

  • rootDir now defaults to ./, so projects with inner source directories must set it explicitly to preserve their directory structure.

    7.0.2release notes

  • stableTypeOrdering now defaults to true and cannot be turned off.

    7.0.2release notes

  • strict now defaults to true, so projects may receive stricter type-checking without setting it explicitly.

    6.0.2, 7.0.2release notesrelease notes

  • target now defaults to the current stable ECMAScript version immediately preceding esnext.

    7.0.2release notes

  • target: es5 is no longer supported and now produces a hard error.

    7.0.2release notes

  • types now defaults to [], so projects relying on global declarations must list them explicitly or set it to ["*"].

    6.0.2, 7.0.2release notesrelease notes

  • Allows command-line builds to take file paths when the current directory contains a tsconfig.json file.

    6.0.2, 7.0.2release notesrelease notes

  • The module keyword can no longer be used in namespace declarations.

    7.0.2release notes

New APIs and options 4

  • Controls how many project-reference builders can run in parallel under --build, which can speed up monorepo builds at increased memory cost.

    7.0.2release notes

  • Controls the number of type-checker workers; increasing it can speed up builds but may increase memory use.

    7.0.2release notes

  • Disables parallelization throughout the compiler, including parsing and emitting, for debugging or resource-constrained environments.

    7.0.2release notes

  • A compatibility package provides the TypeScript 6.0 API and a tsc6 executable, allowing TypeScript 6 tooling to run alongside TypeScript 7.

    7.0.2release notes

Performance 2

  • The native Go port brings native code speed, shared-memory multithreading, and optimizations that typically yield 8x–12x speedups on full builds.

    7.0.2release notes

  • Watch mode is rebuilt on a cross-platform file-watcher foundation and provides significant resource improvements.

    7.0.2release notes

Behavior and default changes 3

  • libReplacement now defaults to false.

    6.0.2, 7.0.2release notesrelease notes

  • JavaScript analysis is reworked to be more consistent with TypeScript files, changing supported JSDoc forms and special handling of JavaScript patterns.

    7.0.2release notes

  • Nightly builds will resume under the standard typescript package with the next tag, installable through npm.

    7.0.2release notes

Tooling 2

  • The language server adds auto-imports, expandable hovers, inlay hints, code lenses, go-to-source-definition, JSX linked editing and tag completions, semantic highlighting, and import-management features.

    7.0.2release notes

  • The new language server reduces failing commands by over 80% and server crashes by over 60% compared with TypeScript 6.0.

    7.0.2release notes

Fixes and other changes 1

  • Inference now treats Unicode code points as single units, so a leading emoji is inferred as one character rather than two UTF-16 surrogate halves.

    7.0.2release notes

typescript 631 changes

Breaking changes 14

  • The amd-module directive no longer has any effect.

    6.0.2release notes

  • The asserts keyword in import declarations is deprecated; use with for import attributes instead.

    6.0.2release notes

  • baseUrl is deprecated and is no longer a module-resolution lookup root; move prefixes into paths entries or add an explicit catch-all path mapping if needed.

    6.0.2release notes

  • The option is deprecated because it only affects ES5 emit; setting it at all now leads to a deprecation error.

    6.0.2release notes

  • Type-checking function expressions in generic calls, especially generic JSX expressions, can catch more bugs; some calls may need an explicit type argument.

    6.0.2release notes

  • The amd module value is no longer supported.

    6.0.2release notes

  • The none module value is no longer supported.

    6.0.2release notes

  • The systemjs module value is no longer supported.

    6.0.2release notes

  • The umd module value is no longer supported.

    6.0.2release notes

  • The outFile option has been removed; use an external bundler to concatenate output files.

    6.0.2release notes

  • The no-default-lib reference directive is no longer supported; consider using --noLib or --libReplacement instead.

    6.0.2release notes

  • With a tsconfig.json, rootDir now defaults to the directory containing that file; without one, it is still inferred when invoking tsc from the command line.

    6.0.2release notes

  • The target compiler option now defaults to the most recent supported ECMAScript spec version, currently es2025.

    6.0.2release notes

  • Running tsc with file arguments in a directory containing tsconfig.json now produces an error because the config will not be loaded.

    6.0.2release notes

Deprecations 5

  • Setting alwaysStrict to false is deprecated; TypeScript 6.0 assumes all code is in JavaScript strict mode.

    6.0.2release notes

  • The deprecation of import assertion syntax now also applies to import() calls.

    6.0.2release notes

  • Using module to declare a namespace is now a hard deprecation; use namespace instead.

    6.0.2release notes

  • The node/node10 resolution strategy is deprecated; migrate to nodenext for Node.js or bundler for bundler and Bun projects.

    6.0.2release notes

  • The es5 target is deprecated, and TypeScript's lowest target is now ES2015; use a newer target or an external compiler for ES5 output.

    6.0.2release notes

New APIs and options 7

  • Adds library types for the Map and WeakMap getOrInsert method.

    6.0.2release notes

  • Adds library types for the Map and WeakMap getOrInsertComputed method, which computes a default only when the key is absent.

    6.0.2release notes

  • Adds es2025 as a library option, providing types for built-in APIs and moving some declarations from esnext into es2025.

    6.0.2release notes

  • Adds RegExp.escape to the es2025 library types for escaping special regular expression characters in literal strings.

    6.0.2release notes

  • TypeScript supports Node.js subpath imports beginning with #/ when moduleResolution is nodenext or bundler.

    6.0.2release notes

  • Adds es2025 as a target option, providing types for built-in APIs and moving some declarations from esnext into es2025.

    6.0.2release notes

  • Adds built-in types for the Temporal API, available with --target esnext, lib: ["esnext"], or the more granular esnext.temporal.

    6.0.2release notes

Behavior and default changes 5

  • The declarations from dom.iterable and dom.asynciterable are now included in dom, so DOM collection iteration works with just lib: ["dom"].

    6.0.2release notes

  • The module compiler option now defaults to esnext.

    6.0.2release notes

  • The bundler module resolution setting can now be combined with --module commonjs.

    6.0.2release notes

  • Aligns TypeScript 6.0 type ordering with TypeScript 7.0 to help diagnose migration differences; it can slow type-checking by up to 25%.

    6.0.2release notes

  • Functions that do not use this are no longer considered contextually sensitive, allowing them to receive higher priority during type inference.

    6.0.2release notes