Skip to content

Commit 5663dbb

Browse files
committed
test revert
1 parent 946d6a5 commit 5663dbb

File tree

6 files changed

+4
-23
lines changed

6 files changed

+4
-23
lines changed

examples/vite-webpack-rspack/dynamic-remote/src/SignUpBanner.jsx

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,9 @@
1-
import _ from 'lodash';
21
const SignUpBanner = () => {
32
return (
4-
<div
5-
data-testid="dynamic-signup-banner"
6-
className="bg-blue-500 text-white p-4 m-4 rounded ring-offset-ring-4 flex justify-between"
7-
>
3+
<div className="bg-blue-500 text-white p-4 m-4 rounded ring-offset-ring-4 flex justify-between">
84
<div>
95
<h2 className="text-xl">Sign up now!</h2>
106
<p>Get started with our amazing service today.</p>
11-
<p data-testid="lodash-version-display">Shared lodash v{_.VERSION}</p>
127
<button className="bg-white text-blue-500 p-2 rounded mt-2">Sign up</button>
138
</div>
149
<img src="https://picsum.photos/200/200" alt="Random" className="mt-2" />

examples/vite-webpack-rspack/dynamic-remote/src/SpecialPromo.jsx

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,8 @@
1-
import _ from 'lodash';
21
const SpecialPromo = () => {
32
return (
4-
<div
5-
data-testid="dynamic-special-promo"
6-
className="bg-red-500 text-white p-4 m-4 rounded ring-offset-ring-4 flex justify-between"
7-
>
3+
<div className="bg-red-500 text-white p-4 m-4 rounded ring-offset-ring-4 flex justify-between">
84
<div>
95
<h2 className="text-xl">Up to 50% off!</h2>
10-
<p data-testid="lodash-version-display">Shared lodash v{_.VERSION}</p>
116
<p>Only for a limited time.</p>
127
</div>
138
<img src="https://picsum.photos/200/200" alt="Random" className="mt-2" />

examples/vite-webpack-rspack/dynamic-remote/vite.config.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,7 @@ export default defineConfig({
1414
'./SignUpBanner': './src/SignUpBanner.jsx',
1515
'./SpecialPromo': './src/SpecialPromo.jsx',
1616
},
17-
shared: {
18-
react: { singleton: true },
19-
'react-dom': { singleton: true },
20-
lodash: { singleton: true, import: false },
21-
},
17+
shared: ['react', 'react-dom'],
2218
}),
2319
],
2420
server: {

examples/vite-webpack-rspack/host/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
},
1212
"dependencies": {
1313
"@module-federation/vite": "workspace:*",
14-
"lodash": "^4.17.21",
1514
"react": "^18.3.1",
1615
"react-dom": "^18.3.1"
1716
},

examples/vite-webpack-rspack/host/src/App.tsx

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,6 @@ import { Toggle } from './components/Toggle';
77
import { useDynamicImport } from './hooks/useDynamicImport';
88
import './index.css';
99

10-
import _ from 'lodash';
11-
_.VERSION;
12-
1310
const RemoteProduct = lazy(
1411
() =>
1512
// @ts-ignore

examples/vite-webpack-rspack/host/vite.config.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ const mfConfig = {
2222
type: 'module',
2323
},
2424
},
25-
shared: ['react', 'react-dom', 'lodash'],
25+
shared: ['react', 'react-dom'],
2626
};
2727

2828
// https://vitejs.dev/config/
@@ -38,6 +38,5 @@ export default defineConfig({
3838
],
3939
build: {
4040
target: 'chrome89',
41-
minify: false,
4241
},
4342
});

0 commit comments

Comments
 (0)