You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 307cefb
Browse filesBrowse the repository at this point in the historyBrowse files
fix(nuxt): Fix CommonJS interop for force-inlined instrumented packages (#24799)
Since v11, build-time instrumentation force-inlines the instrumented
drivers (mongoose, ioredis, mysql, ...) into the Nitro bundle while
their CommonJS dependencies stay external. Since Node 23, CJS namespaces
carry a `module.exports` key next to `default` (nodejs/node#53848), so
Rollup's `'auto'` interop no longer unwraps those requires and the
drivers crash at startup (`mquery is not a constructor`).
No single interop mode (a `requireReturnsDefault` value) fixes this and
works for all externals. `debug` needs the namespace, while `mquery` and
`lodash.defaults` need `module.exports`. So we unwrap builtins plus a
known list and keep `'auto'` for the rest.
Fixes#24775Fixes#24786
0 commit comments