Files
vercel__workflow/.changeset/lazy-discovery-default.md
Nathan Rajlich 070bd0cea9 [next] make lazyDiscovery the default in withWorkflow (#1805)
* [next] make lazyDiscovery the default in withWorkflow

Flips the default for `workflows.lazyDiscovery` from `false` to `true`
so new projects get deferred workflow discovery automatically on Next.js
versions that support deferred entries (>= 16.2.0-canary.48). Older
versions continue to fall back to eager discovery.

Users can still opt back into eager discovery explicitly by passing
`workflows: { lazyDiscovery: false }`.

Also:
- Remove the now-redundant `lazyDiscovery: true` from the Next.js
  workbench apps.
- Reword the fallback warning for clarity when lazy is the default.
- Update the local-build e2e assertion to match the new warning text.
- Update the withWorkflow docs with the new default.

* [workbench] remove commented 'export default nextConfig' lines
2026-05-22 14:11:34 +00:00

433 B

@workflow/next
@workflow/next
minor

Change lazyDiscovery default to true for withWorkflow. Workflow discovery is now deferred until files are requested instead of scanning eagerly at startup on Next.js versions that support deferred entries (>= 16.2.0-canary.48). Older versions automatically fall back to eager discovery. Pass workflows: { lazyDiscovery: false } to opt back into eager discovery on supported Next.js versions.