text: // module.exports = {
  //   module: {
  //     rules: [{
  //       test: /\.m?js$/,
  //       exclude: /node_modules/,
  //       use: {
  //         loader: 'babel-loader',
  //         options: {
  //           preset: ['@babel/preset-react','@babel/preset-env'],
  //           plugins: ['@babel/plugin-transform-runtime']
  //         }
  //       }
  //     }]
  //   }
  // }
  
  const { merge } = require('webpack-merge');
  const ModuleFederationPlugin = require('webpack/lib/container/ModuleFederationPlugin');
  const packageJson = require('../package.json');
  
  const commonConfig = require('./webpack.common');
  
  const prodConfig = {
    mode: 'production',
    output: {
      filename: '[name].[contenthash].js',
      publicPath: '/home/latest/',
    },
    plugins: [
      new ModuleFederationPlugin({
        name: 'home',
        filename: 'remoteEntry.js',
        exposes: {
          './HomeApp': './src/bootstrap'
        },
        shared: packageJson.dependencies
      })
    ]
  }
  
  
  module.exports = merge(commonConfig, prodConfig);
  
  