File tree 2 files changed +15
-1
lines changed
2 files changed +15
-1
lines changed Original file line number Diff line number Diff line change
1
+ // Webpack entry point for module federation.
2
+ import "@patternslib/patternslib/webpack/module_federation" ;
3
+ // The next import needs to be kept with brackets, otherwise we get this error:
4
+ // "Shared module is not available for eager consumption."
5
+ import ( "./bundle-config" ) ;
Original file line number Diff line number Diff line change 1
1
process . traceDeprecation = true ;
2
+ const mf_config = require ( "@patternslib/patternslib/webpack/webpack.mf" ) ;
3
+ const package_json = require ( "./package.json" ) ;
2
4
const path = require ( "path" ) ;
3
5
const patternslib_config = require ( "@patternslib/patternslib/webpack/webpack.config.js" ) ;
4
6
5
7
module . exports = async ( env , argv ) => {
6
8
let config = {
7
9
entry : {
8
- bundle : path . resolve ( __dirname , "bundle-config .js" ) ,
10
+ " bundle.min" : path . resolve ( __dirname , "index .js" ) ,
9
11
} ,
10
12
} ;
11
13
12
14
config = patternslib_config ( env , argv , config ) ;
13
15
config . output . path = path . resolve ( __dirname , "dist/" ) ;
14
16
17
+ config . plugins . push (
18
+ mf_config ( {
19
+ package_json : package_json ,
20
+ remote_entry : config . entry [ "bundle.min" ] ,
21
+ } )
22
+ ) ;
23
+
15
24
if ( process . env . NODE_ENV === "development" ) {
16
25
config . devServer . static . directory = __dirname ;
17
26
}
You can’t perform that action at this time.
0 commit comments