github cloudflare/workers-sdk @cloudflare/vitest-plugin@1.5.0

Minor Changes

  • #16424 1598fd3 Thanks @edmundhung! - Promote experimental.newConfig to a stable config option

    The experimental experimental.newConfig option is now the stable config option. Pass config: true to cloudflareTest() to load your Worker's bindings, entrypoint and compatibility settings from cloudflare.config.ts in the project root, or pass the path of a cloudflare.config.ts elsewhere:

    cloudflareTest({ config: true });
    cloudflareTest({ config: "./worker/cloudflare.config.ts" });

    config can't be combined with wrangler. miniflare options are merged over the Worker from cloudflare.config.ts, with miniflare values taking precedence. Config functions receive Vitest's mode as ctx.mode, which defaults to test and can be changed with --mode.

    If you're moving from experimental.newConfig, secrets are now read from Vite's envDir instead of the directory containing cloudflare.config.ts, and remote bindings authenticate with cf instead of Wrangler.

Patch Changes

  • #16642 d38cb02 Thanks @dependabot! - Update DEFAULT_COMPAT_DATE to 2026-11-02

    Use the bundled workerd release's compatibility date by default when scaffolding new projects or when no compatibility date is configured.

  • #16623 51bbf8b Thanks @petebacondarwin! - Deprecate shared tooling helper exports from Miniflare

    Miniflare continues to export getNodeCompat, NodeJSCompatMode, and getFreshSourceMapSupport for compatibility. These exports are deprecated and now use the implementations in @cloudflare/workers-utils. Add a dependency on that package and replace the Miniflare imports with:

    import {
      getNodeCompat,
      type NodeJSCompatMode,
    } from "@cloudflare/workers-utils/node-compat";
    import { getFreshSourceMapSupport } from "@cloudflare/workers-utils/sourcemap";

    Wrangler and the Cloudflare Vite and Vitest plugins now use the shared helpers directly. The helpers retain their behavior and can be imported without loading the Workers runtime.

    The deprecated Miniflare exports will be removed in a later release, allowing downstream tools such as cf to migrate and release independently first.

  • Updated dependencies [d38cb02, d38cb02, 51bbf8b, e5b1798]:

Don't miss a new workers-sdk release

NewReleases is sending notifications on new releases.