← All stories
● Covered by 1 source · 1 reportMedium impact1 neutral

NestJS 12 Released with ESM Packages, Standard Schema Validation, and Observability SDK

🔄 Updated 19d ago
New to BrevFeed? We gather this story from every outlet covering it into one summary — ranked by real-world impact, not just the latest headline — so you never miss what matters. What is BrevFeed? →

Key points

  • Core packages now ship as ESM, requiring Node.js 20.19+ or 22.12+.
  • Standard Schema validation is integrated, supporting Zod, Valibot, and ArkType.
  • A new official observability SDK, @nestjs/observe, provides framework-level tracing.
  • The CLI was rebuilt, and `nest new` now offers CJS or ESM project generation.

ESM Transition and Tooling Updates

NestJS version 12 moves its core packages to ESM, while maintaining compatibility for existing CommonJS applications through Node.js's `require(esm)` support. This change necessitates Node.js 20.19+ or 22.12+. New projects generated with `nest new` can now choose between CJS or ESM, with ESM projects defaulting to Vitest and oxlint. Rspack replaces webpack as the monorepo bundler. Benchmarks indicate this transition is primarily a tooling cleanup rather than a performance gain.

Enhanced Schema Validation

The update significantly improves validation ergonomics. Route decorators like `@Body()`, `@Query()`, and `@Param()` now accept a `schema` option, allowing direct use of any Standard Schema compatible object from libraries such as Zod, Valibot, and ArkType without third-party wrappers. `class-validator` remains the default documented option. This approach allows developers to choose their preferred validation library while reducing boilerplate.

Official Observability SDK

NestJS 12 introduces `@nestjs/observe`, an official observability SDK that integrates with the framework's lifecycle to report traces in terms of controllers and providers. This SDK offers richer context compared to patching the HTTP server. However, it is specific to NestJS, lacks out-of-the-box cross-stack correlation, and may lead to framework-level vendor lock-in. A new `nest deploy` command, which forwards to the Mau platform, also points towards first-party services.

Upgrade Process and Other Changes

Upgrading from NestJS v11 involves installing the latest CLI and running `nest upgrade`. This command updates all `@nestjs/*` packages to v12, bumps TypeScript to v6, and applies mechanical changes such as switching from GraphQL Playground to GraphiQL and updating to the NATS v3 client.

✨ This summary was generated by AI from the outlets' reporting listed below. It is not independently verified and may contain errors — check the original sources. How BrevFeed works →

The daily brief

One email each morning: the day's tech stories, clustered across outlets and summarized. No account needed.

One email a day. Unsubscribe in one click, any time.

Today's brief

Spend a few minutes, get the whole day. Every topic's top stories in one hands-free rundown — listen, watch, or read the transcript.

~4 min · 3 stories · Nov 07

▶ Play today's brief Listen on Spotify

New every morning, and the back catalogue is archived by date.

Primary sources

GitHub nestjs/nest

Reporting from

NestJS, a TypeScript framework for Node.js, released version 12, which transitions core packages to ESM, adds first-class Standard Schema validation, and introduces an official observability SDK. This update modernizes the framework's tooling and improves developer experience for validation and monitoring.