Add module-sync
condition to default ssr.resolve.externalCondition
#19201
Labels
module-sync
condition to default ssr.resolve.externalCondition
#19201
Description
module-sync
condition is a condition enabled by Node.js whenrequire(esm)
is enabled. It is supported by the config loader (#18650), but not by the SSR module loader.Suggested solution
Add
module-sync
condition to defaultssr.resolve.externalCondition
.Alternative
Leave it as-is and tell users to configure it when needed.
Additional context
exports
field #18300export { foo as 'module.exports' }
(module: support 'module.exports' interop export name in require(esm) nodejs/node#54563) in the config loader but we should support that as wellmodule-sync
tossr.resolve.conditions
is to follow Node.js's recommendation.Quoting from the Node 22.10.0 release post:
Validations
The text was updated successfully, but these errors were encountered: