Node.js Modern Batteries-Included Built-ins

Parent: JavaScript and Node.js · researched 2026-06-02T18:03:38.683Z· 19 sources · 7 concepts · skill nodejs-builtin-modules-modern

Between Node.js v20 and v26 (2024-2026) the runtime absorbed a wave of capabilities that

Overview

1. `node:sqlite` — a built-in synchronous SQLite driver

2. The global `WebSocket` client (undici-backed)

3. Environment files — `--env-file`, `loadEnvFile()`, `util.parseEnv()`

4. Task running (`node --run`) and watch mode (`--watch`)

5. Filesystem & utility built-ins: `fs.glob`, `util.styleText`, `structuredClone`, `navigator`

6. Module compile cache — `module.enableCompileCache()` / `NODE_COMPILE_CACHE`

7. (Pointer) `node:test` — the built-in test runner

8. CLI app building with built-ins (`util.parseArgs`, `readline/promises`, signals, exit codes)

Practical patterns

Anti-patterns

Troubleshooting

References

Children

Frontier under this node: CLI app building with built-ins (util.parseArgs, readline/promises, signals, exit codes), Environment files: --env-file / --env-file-if-exists / process.loadEnvFile() / util.parseEnv() — replaces dotenv, Filesystem & utils: fs.glob/globSync, util.styleText(), structuredClone, navigator — replace glob/chalk/lodash.cloneDeep/os.cpus, Global undici-backed WebSocket client (client-only) — replaces ws for client use, Module compile cache: module.enableCompileCache() / NODE_COMPILE_CACHE — startup performance, Task running & watch: node --run + --watch / --watch-path / --watch-preserve-output — replaces npm run / nodemon, node:sqlite (DatabaseSync/StatementSync, params, aggregate, backup) — replaces better-sqlite3

← the whole tree · 3D view· how to read this page