next.js
a5def42a - Remove rsc esm client module extra exports (#65519)

Commit
1 year ago
Remove rsc esm client module extra exports (#65519) Remove the extra `__esModule` and `$$typeof` export for ESM client module For a client page reference, it changed on server side in renderer: Previous: `{ __esModule, $$typeof, default }` Now: `{ default }` The Module object itself appears as a client reference but it can't be rendered since it's not a real reference. I'm not sure why it was added but I think the right thing for an ESM module is to not treat the module itself as a client reference but only the objects inside of it. E.g. the "default" export. That's what React does upstream for ESM modules. Closes NEXT-3360
Author
Committer
Parents
Loading