jsconfig.json option

noEmit

  • Default false
  • true in jsconfig.json
  • Tested with TypeScript 5.9

By default tsc checks your files and then writes output: .js files, and .d.ts files if you ask. In a JavaScript project your source already is the output, so all you want is the checking. noEmit turns the writing off.

A file named jsconfig.json defaults noEmit to true. A tsconfig.json does not: with allowJs and no outDir, tsc would write each .js file over itself, so it stops with TS5055 for every file instead.

At a glance

Write "noEmit": true (already the default in a jsconfig.json; write it anyway so the file says what it does)
On the command line --noEmit
Type boolean
Default in TypeScript 5.9 false
Default in a jsconfig.json true
TypeScript's description Disable emitting files from a compilation.
In the quick-start setups
Generator, relaxed true
Generator, recommended true
Generator, strict true

The description is quoted from TypeScript's own option list (Apache-2.0); see the notices. The setup values are the checked configs on the quick-start pages. The generator rows are what the jsconfig generator writes at each level.

The error without it

This is what tsc prints for a tsconfig.json that sets allowJs (or checkJs) and neither noEmit nor outDir. The path is your own file; the message is the same in every project:

Terminal
$ npx tsc -p tsconfig.json
error TS5055: Cannot write file '/home/ada/shop/src/cart.js' because it would overwrite input file.

When you do want output: .d.ts files

A package written in JavaScript can still ship types: declaration with emitDeclarationOnly writes .d.ts files and never touches your .js. Keep that in a second config file, so the everyday jsconfig.json stays a pure check with noEmit.

If that second config extends your jsconfig.json, it inherits noEmit: true, the jsconfig.json default, even when the file never writes it. Set "noEmit": false in the second config, or tsc writes nothing and says nothing.

Gotchas

  • noEmit silently wins over emitDeclarationOnly: TypeScript 5.9 reports no error for the pair, and no file is written.
  • noEmit skips the writing, not any of the checking: the same errors are reported either way. For a faster run, see skipLibCheck.

Questions

Does noEmit change how my code runs?

No. With noEmit nothing is written, so what runs is exactly the JavaScript you wrote. Without it, tsc writes output files, and only those can differ from the code you wrote.

Sources

Last reviewed 20 October 2026.