profile
viewpoint
If you are wondering where the data of this site comes from, please visit https://api.github.com/users/JohnDaly/events. GitMemory does not store any data, but only uses NGINX to cache data for a period of time. The idea behind GitMemory is simply to give users a better reading experience.
John Daly JohnDaly Convoy https://johnmcdaly.com Front-end Engineer @convoyinc

tvillarete/ipod-classic-js 1048

An iPod Classic that connects to Apple Music and Spotify. Built with React & Styled Components

JohnDaly/react-progressive-image-hooks 1

A progressive image component + hooks for React

aitchpat/unslackd 0

Slack app for Untappd

JohnDaly/gohttp 0

An HTTP networking client written in go.

JohnDaly/ipod-classic-js 0

An iPod Classic that connects to Apple Music and Spotify. Built with React & Styled Components

JohnDaly/next.js 0

The React Framework

JohnDaly/nextjs-mf-issues 0

A small example app that demonstrates some issues with module federation in NextJS

JohnDaly/site 0

react-pdf public site https://react-pdf.org

fork JohnDaly/next.js

The React Framework

https://nextjs.org

fork in 14 days

issue commentmodule-federation/module-federation-examples

Material-ui/lab and material-ui/pickers overriding styles when being imported from remote federated modules

It could be because you're not specifying a version requirement for the @material-ui/core dependency, and you're getting a different copy which introduces the styling discrepancies.

When Webpack tries to determine which copy of that library to use, it will find the highest version available (unless told otherwise). If @material-ui/lab or @material-ui/pickers have the @material-ui/core package listed as a peerDependency, then you could be getting a version of the library that causes the problem you're seeing.

jmelendez-cbs

comment created time in 2 months

issue commentmodule-federation/module-federation-examples

What does this comment mean?

This is what the Webpack docs have to say about this configuration hint:

import false | string The provided module that should be placed in the shared scope. This provided module also acts as fallback module if no shared module is found in the shared scope or version isn't valid. (The value for this hint defaults to the property name.)

From: https://webpack.js.org/plugins/module-federation-plugin/#import

I think you might use it if the property name that you're passing to the shared object doesn't match the actual module name? It seems like the usage of this override would be rare.

As far as I can tell in this example, it looks like all of the hints here are the defaults (except for singleton). I think this example could be re-written as:

new ModuleFederationPlugin({
  name: "app1",
  // adds react as shared module
  // version is inferred from package.json
  // there is no version check for the required version
  // so it will always use the higher version found
  shared: {
    react: {
      singleton: true, // only a single version of the shared module is allowed
    },
    "react-dom": {
      singleton: true, // only a single version of the shared module is allowed
    },
  },
}),
imizaac

comment created time in 2 months