Skip to content

Conversation

@alexlobera
Copy link
Contributor

Next.js v10.2 does not have an async boundary and Webpack doesn't seem to resolve modules in the shared scope.

In this example nextjs (host) and reception (remote) use the same version of React. If you navigate to http://localhost:3001 only 1 copy of React should be downloaded. However, the shared scope doesn't work when using dynamic from "next/dynamic" resulting in React being downloaded twice. This example shows a workaround to solve the issue when SSR the remote is not required.

@CLAassistant
Copy link

CLAassistant commented Jun 2, 2021

CLA assistant check
All committers have signed the CLA.

@ScriptedAlchemy ScriptedAlchemy merged commit c891cc4 into module-federation:master Jun 2, 2021
@alexlobera alexlobera deleted the nextjs-client-only branch June 3, 2021 10:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants