@appshell/react-refresh-singleton-plugin
v0.12.0
Published
Webpack plugin used to enable react-refresh hot module replacement for distributed frontends using Module Federation
Maintainers
Readme
@appshell/react-refresh-singleton-plugin
A single instance of react-refresh/runtime to enable react-refresh hot module replacement for distributed frontends using Module Federation.
Working examples can be found here.
Getting Started
To begin, you'll need to install @appshell/react-refresh-singleton-plugin:
npm install @appshell/react-refresh-singleton-plugin --save-devor
yarn add -D @appshell/react-refresh-singleton-pluginor
pnpm add -D @appshell/react-refresh-singleton-pluginThen add the plugin to the webpack config of each remote app module. For example:
webpack.config.js
const ReactRefreshSingleton = require('@appshell/react-refresh-singleton-plugin');
module.exports = {
plugins: [new ReactRefreshSingleton()],
};