Skip to content

VSCode extension does not appear to work with typeRoots #2147

@ScottKaye

Description

@ScottKaye

Extension Version

0.20251121.1

VS Code Version

1.106.2

Operating system Version

MacOS Tahoe 26.1

Steps to reproduce

  1. Clone this repo: https://github.com/ScottKaye/tsgo-repro/tree/master
  2. cd assets && npm i
  3. Open the base folder (tsgo-repro) in VS Code
  4. Toggle the TypeScript Native extension
Image Image

Issue

With the extension disabled, types work.

Image

However, with the extension enabled (tsgo running), types do not work:

Image

There's nothing that appears to be useful in the logs.

Admittedly, this is a non-standard file layout. It reproduces the structure of a large monorepo I'm working in, where packages are managed in a subdirectory (assets) that isn't a direct ancestor of my application (app). tsconfig uses typeRoots to point at the alternative placement of node_modules, but this doesn't seem to be being followed by tsgo.

Metadata

Metadata

Labels

Domain: Module ResolutionRelated to module resolution and module checker errorsDomain: ProgramRelated to the Program, file loading

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions