How to Build a TypeScript Project for Both CJS and ESM Targets
Too Long; Didn't Read
This article will describe how we can build a TypeScript project for both CJS and ESM targets using a pure TypeScript compiler and native npm features. You can find an example project in my GitHub [repo]:https://github.com/sr-shifu/ts-build-octopus.