Change8

@cloudflare/unenv-preset@2.7.13

📦 cloudflare-workersView on GitHub →
2 features🔧 2 symbols

Summary

This patch introduces the use of native workerd modules like 'node:console' and 'node:vm' when specific compatibility flags are set or future dates are reached, improving Node.js compatibility.

Migration Steps

  1. If you rely on specific console behavior that might change with the introduction of 'node:console', monitor behavior when the 'enable_nodejs_console_module' flag becomes true by default.
  2. If you rely on specific VM behavior that might change with the introduction of the native 'node:vm' module, monitor behavior when it becomes enabled by default starting 2025-10-01.

✨ New Features

  • Use workerd 'node:console' when it is available, enabled when the 'enable_nodejs_console_module' compatibility flag is set (defaults to true when 'nodejs_compat' is on and date is >= 2025-09-21).
  • Use native 'node:vm' module when available, enabled starting on 2025-10-01 or when the 'enable_nodejs_vm_module' compatibility flag is set.

🔧 Affected Symbols

node:consolenode:vm