Module

Module Build system

ESM

ECMAScript modules

There are many module systems, and TypeScript supports emitting several, but this documentation will focus on the two most important systems today: ECMAScript modules (ESM) and CommonJS (CJS). ECMAScript Modules (ESM) is the module system built into the language, supported in modern browsers and in Node.js since v12.

CJS

CommonJS (CJS)