Microsoft/vscode
View on GitHubtypescript language features do not resolve tsconfig extends specifier with package exports subpath remapping
Open
#276592 opened on Nov 10, 2025
bughelp wantedtypescript
Description
Does this issue occur when all extensions are disabled?: Yes
- VS Code Version: any
- OS Version: any
Steps to Reproduce:
- Extend a tsconfig from your (or another) package and/or project. The exact specifier does not matter, as long as it is correct (according to what is exported/exposed in that package):
and the dependency, in case you don't extend from within the same package:{ "//": "my tsconfig", "extends": "@scope/example/base/tsconfig.json" }{ "//": "my package.json", "name": "@scope/my-package", "type": "module", "devDependencies": { "@scope/example": "*" } } - Remap export paths in the package/project to extend from. In theory this could be the package housing the project from step (1) itself, or another package in your mono repo, or a third party package. In practice this has been tested in a mono repo with one package/project/workspace depending on another package/project/workspace in the same mono repo:
{ "//": "other package.json", "name": "@scope/example", "type": "module", "exports": { "./*/tsconfig.json": "./lib/*/tsconfig.json" } } - Observe that TypeScript correctly resolves the specifier from step (1). You can test this by running the type checker, or by trusting the VSCode problems panel not to show any problems about that config.
- Observe that the VSCode TypeScript and JavaScript language features fail to resolve the config specifier. For example
cmd + clickto follow the link does not work. - Observe that using an (incorrect) specifier, which ignores the exports field of the dependency makes
cmd + clickwork, but the type checker (correctly) is not able to resolve this specifier. In this example this could be something like the following, assuming there is atsconfig.jsonin./lib/base/of the@scope/examplepackage:{ "//": "my tsconfig", "extends": "@scope/example/lib/base/tsconfig.json" }
Edit: Removed unnecessary steps. Added a repro repo instead: https://github.com/valler/repro-repo-for-ms-vscode-issue-276592