Urgent.News

What's breaking now, across thousands of outlets.

Tech

Node 24 Runs TypeScript With No Build Step. Here's What It Won't Do.

Node 24 Runs TypeScript With No Build Step. Here's What It Won't Do. node server.ts works. No flag, no loader, no tsx , no dist/ folder. Node 24 reads the TypeScript, throws the types away, and runs what is left. The flag everybody still types — --experimental-strip-types — has been unnecessary since Node 23.6, and on 24 you can pass it or leave it off and get byte-identical output. I typed it…

Node 24 allows running TypeScript code without a build step, eliminating the need for flags, loaders, or a "dist/" folder. The TypeScript annotations are replaced with equivalent blank spaces in the output, preserving the original character length. Node 24 reads the TypeScript code, strips away the type information, and executes the remaining JavaScript.

This mechanism is achieved through the Amaro wrapper, which compiles TypeScript to WebAssembly and hands the result to V8. However, this zero-build approach has limitations:

1. Node does not read the tsconfig.json file, ignoring settings like paths, experimentalDecorators, and target.

2. There is no type checking performed, and no validation or resolution of TypeScript files occurs.

3. Node cannot generate code, so features requiring JavaScript emission are not possible.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in Tech

More from Tuesday 22 September →