mirror of https://github.com/webpack/webpack.git
27 lines
536 B
JavaScript
27 lines
536 B
JavaScript
const { dependencies } = require("./package.json");
|
|
const { ModuleFederationPlugin } = require("../../../../").container;
|
|
|
|
/** @type {import("../../../../").Configuration} */
|
|
module.exports = {
|
|
optimization: {
|
|
chunkIds: "named",
|
|
moduleIds: "named"
|
|
},
|
|
plugins: [
|
|
new ModuleFederationPlugin({
|
|
name: "container",
|
|
filename: "container.js",
|
|
library: { type: "commonjs-module" },
|
|
exposes: {
|
|
"./emitter": {
|
|
name: "emitter",
|
|
import: "./emitter.js"
|
|
}
|
|
},
|
|
shared: {
|
|
...dependencies
|
|
}
|
|
})
|
|
]
|
|
};
|