Skip to content

Commit 953bcb6

Browse files
chore: general housekeeping (#4001)
Co-authored-by: ScriptedAlchemy <[email protected]>
1 parent 5a8edde commit 953bcb6

File tree

2 files changed

+6
-14
lines changed

2 files changed

+6
-14
lines changed

basic-host-remote/app1/modern.config.js

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,20 @@
11
import appTools, { defineConfig } from '@modern-js/app-tools';
2-
import {ModuleFederationPlugin} from "@module-federation/enhanced"
2+
import { ModuleFederationPlugin } from '@module-federation/enhanced/webpack';
33

44
// https://modernjs.dev/en/configure/app/usage
55
export default defineConfig({
66
server: {
77
port: 3001,
88
},
9-
// dev: {
10-
// // set publicPath
11-
// assetPrefix: 'http://localhost:3001/',
12-
// },
139
runtime: {
1410
router: true,
1511
},
1612
source: {
17-
// automatically generated asynchronous boundary via Dynamic Import, allowing the page code to consume remote modules generated by the module federation.
13+
// Automatically generated asynchronous boundary via Dynamic Import, allowing the page code to consume remote modules generated by the module federation.
1814
enableAsyncEntry: true,
1915
},
2016
tools: {
21-
webpack: (config, { webpack, appendPlugins }) => {
17+
webpack: (config, { appendPlugins }) => {
2218
delete config.optimization.splitChunks;
2319
config.output.publicPath = 'auto';
2420

basic-host-remote/app2/modern.config.js

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,11 @@
1-
import appTools, { defineConfig } from '@modern-js/app-tools'
2-
import {ModuleFederationPlugin} from "@module-federation/enhanced"
1+
import appTools, { defineConfig } from '@modern-js/app-tools';
2+
import { ModuleFederationPlugin } from '@module-federation/enhanced';
33

44
// https://modernjs.dev/en/configure/app/usage
55
export default defineConfig({
66
server: {
77
port: 3002,
88
},
9-
dev: {
10-
// set publicPath
11-
// assetPrefix: 'auto',
12-
},
139
runtime: {
1410
router: true,
1511
},
@@ -18,7 +14,7 @@ export default defineConfig({
1814
enableAsyncEntry: true,
1915
},
2016
tools: {
21-
webpack: (config, { webpack, appendPlugins }) => {
17+
webpack: (config, { appendPlugins }) => {
2218
delete config.optimization.splitChunks;
2319
config.output.publicPath = 'auto';
2420

0 commit comments

Comments
 (0)