@module-federation/storybook-addon 6.0.1 → 6.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -79,21 +79,23 @@ export default config;
79
79
 
80
80
  ### For the [NX](https://nx.dev/getting-started/intro) projects:
81
81
 
82
- Replace NX utils `withModuleFederation` in `webpack.config.js` with our utils `withModuleFederation`.
82
+ Replace Nx module federation wiring in `webpack.config.js` with a plain webpack config that uses `withModuleFederation`.
83
83
  Example:
84
84
 
85
85
  ```javascript
86
- const { composePlugins, withNx } = require('@nx/webpack');
87
- const { withReact } = require('@nx/react');
86
+ const path = require('path');
87
+ const HtmlWebpackPlugin = require('html-webpack-plugin');
88
88
  const { withModuleFederation } = require('@module-federation/storybook-addon');
89
-
90
89
  const baseConfig = require('./module-federation.config');
91
90
 
92
- const config = {
93
- ...baseConfig,
94
- };
95
-
96
- module.exports = composePlugins(withNx(), withReact(), withModuleFederation(config));
91
+ module.exports = withModuleFederation(baseConfig, { dts: false })({
92
+ mode: 'development',
93
+ context: __dirname,
94
+ entry: {
95
+ main: path.resolve(__dirname, 'src/main.ts'),
96
+ },
97
+ plugins: [new HtmlWebpackPlugin({ template: path.resolve(__dirname, 'src/index.html') })],
98
+ });
97
99
  ```
98
100
 
99
101
  In file `./storybook/main.js`:
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@module-federation/storybook-addon",
3
- "version": "6.0.1",
3
+ "version": "6.0.2",
4
4
  "description": "Storybook addon to consume remote module federated apps/components",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -62,8 +62,8 @@
62
62
  "webpack-virtual-modules": "0.6.2"
63
63
  },
64
64
  "peerDependencies": {
65
- "@rsbuild/core": "2.0.0-beta.2",
66
- "@module-federation/sdk": "^2.0.1",
65
+ "@rsbuild/core": "^1.0.1 || ^2.0.0-0",
66
+ "@module-federation/sdk": "^2.1.0",
67
67
  "@nx/react": ">= 16.0.0",
68
68
  "@nx/webpack": ">= 16.0.0",
69
69
  "@nx/module-federation": ">= 16.0.0",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@module-federation/storybook-addon",
3
- "version": "6.0.1",
3
+ "version": "6.0.2",
4
4
  "description": "Storybook addon to consume remote module federated apps/components",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -49,8 +49,8 @@
49
49
  }
50
50
  },
51
51
  "dependencies": {
52
- "@module-federation/sdk": "2.0.1",
53
- "@module-federation/enhanced": "2.0.1"
52
+ "@module-federation/enhanced": "2.1.0",
53
+ "@module-federation/sdk": "2.1.0"
54
54
  },
55
55
  "devDependencies": {
56
56
  "jest-fixed-jsdom": "^0.0.9",
@@ -59,11 +59,11 @@
59
59
  "@storybook/core": "^8.4.6",
60
60
  "webpack": "5.104.1",
61
61
  "webpack-virtual-modules": "0.6.2",
62
- "@module-federation/utilities": "3.1.84"
62
+ "@module-federation/utilities": "3.1.85"
63
63
  },
64
64
  "peerDependencies": {
65
- "@rsbuild/core": "2.0.0-beta.2",
66
- "@module-federation/sdk": "^2.0.1",
65
+ "@rsbuild/core": "^1.0.1 || ^2.0.0-0",
66
+ "@module-federation/sdk": "^2.1.0",
67
67
  "@nx/react": ">= 16.0.0",
68
68
  "@nx/webpack": ">= 16.0.0",
69
69
  "@nx/module-federation": ">= 16.0.0",