Pure ESM monorepo usage native TypeScript compiler 🌟
MIT License
Pure ESM monorepo using native TypeScript compiler instead of external bundlers 🌟
Node.js 22.2.0 or newer is required
NPM 10.8.0 or newer is required
git clone https://github.com/negezor/typescript-monorepo-boilerplate.git
cd typescript-monorepo-boilerplate
npm install
npm run build
tsconfig.json
, change the paths
from @template
to the one you needname
property of the package.json
file of each modulepackage.json
, change workspaces
and path in scripts lint:biome
& typescript:clean
tsconfig.json
, change the paths
.gitignore
, change the # Build
placenpm run update:tsconfig
for update tsconfig referencesnpm run update:tsconfig
for update tsconfig referencesnpm install
for create new symlinks in node_modulespackage.json
dependency in peerDependencies
npm run update:tsconfig
for update tsconfig referencesnpm run build
npm run watch
npm run test
npm run lint
npm run fmt
npm run clean
npm run build --workspaces
npm run build --workspace=name
Because they are external dependencies, yes of course they can faster than the typescript compiler for a build. But we will still check types and it is trivially easier. It's worth noting that now we use tsx which depends on esbuild (will be replaced later with a simpler solution).
It's very simple, eslint is very slow. Usually the rules that we often need are already available in Biome.js, and those that are not are probably will implemented in the next version. It is also worth noting that eslint pulls a lot of small dependencies, while Biome.js is 1 binary file for your platform, which is much faster when installing and updating dependencies. Also it provides a formatter out of the box, we don't need to install prettier separately.
Because these are external dependencies, and node:test
is available out of the box, plus it's faster. The only thing that may be missing is simpler expect comparison, but you can put a smaller module for that separately.