Replies: 2 comments 1 reply
-
@yspychala Did you had more insights on this issue? |
Beta Was this translation helpful? Give feedback.
0 replies
-
@MilaRCDias No, unfortunately we decided to both drop Styled Components in favor of Tailwind because of performance issues with Next.js in production, and to forget the idea to implement Module Federation. Next.js makes it really hard and unstable to use MF, and as a big company, we cannot take this risk. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
In order to have styles from styled-components generated server-side in a Next.js application, we need to modify the _document.js like this:
Then, if in this application I consume some remotes thanks to the
@module-federation/nextjs-mf
plugin, there’s a need to revalidate the document if a remote changes, either in development mode or in production. If I follow the example from the nextjs-ssr example, this must be changed like this:I tried various combination of both, but I must say I’m a bit lost of what’s happening underneath. Is there an example somewhere I could look into?
Thanks a lot for your help!
Beta Was this translation helpful? Give feedback.
All reactions