TS2580: Cannot find name 'process' - in CI
tsc does not know Node globals like process, require, __dirname, or Buffer without the Node type definitions.
What this error means
Type-checking fails with TS2580 and a hint to install type definitions for node.
tsc
src/config.ts(1,13): error TS2580: Cannot find name 'process'. Do you need to install type definitions for node? Try `npm i --save-dev @types/node`.Common causes
How to fix it
Install @types/node
- Add the Node type declarations as a dev dependency
shell
npm i -D @types/nodeEnsure node is included
- If you pin compilerOptions.types, list node explicitly
tsconfig.json
{
"compilerOptions": {
"types": ["node", "vite/client"]
}
}How to prevent it
- Install @types/node wherever build scripts or config touch Node globals, and avoid an over-restrictive types allowlist.
Related guides
TS2304: Cannot find name - in CIFix "error TS2304: Cannot find name 'x'" when tsc runs in CI - a missing import, a missing lib/types entry, o…
TS7016: Could not find a declaration file for module - in CIFix "error TS7016: Could not find a declaration file for module 'x'. '...' implicitly has an 'any' type" when…
TS2688: Cannot find type definition file for - in CIFix "error TS2688: Cannot find type definition file for 'x'" when tsc runs in CI - a types entry that is not…