Skip to content

tsc needs "types": ["node"], tsgo doesn't #3023

@s-h-a-d-o-w

Description

@s-h-a-d-o-w

Steps to reproduce

https://github.com/s-h-a-d-o-w/tsgo-repro/tree/node-globals

Behavior with "typescript": "6.0.0-dev.20260307"

playwright.config.ts:3:15 - error TS2591: Cannot find name 'process'. Do you need to install type definitions for node? Try `npm i --save-dev @types/node` and then add 'node' to the types field in your tsconfig.

3 const isDev = process.env["NODE_ENV"] !== "production";
                ~~~~~~~

playwright.config.ts:12:8 - error TS2591: Cannot find name 'process'. Do you need to install type definitions for node? Try `npm i --save-dev @types/node` and then add 'node' to the types field in your tsconfig.

12     ...process.env,
          ~~~~~~~

playwright.config.ts:25:17 - error TS2591: Cannot find name 'process'. Do you need to install type definitions for node? Try `npm i --save-dev @types/node` and then add 'node' to the types field in your tsconfig.

25   forbidOnly: !!process.env["CI"],
                   ~~~~~~~


Found 3 errors in the same file, starting at: playwright.config.ts:3

Behavior with "@typescript/native-preview": "7.0.0-dev.20260307.1",

No output.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions