text: const config = require('./webpack.base');
  const merge = require('webpack-merge');
  const { resolve } = require('./utils');
  const ExtractTextPlugin = require('extract-text-webpack-plugin');
  const MiniCssExtractPlugin = require('mini-css-extract-plugin');
  const OptimizeCSSAssetsPlugin = require('optimize-css-assets-webpack-plugin');
  
  module.exports = merge(config, {
  	mode: 'production',
  	module: {
  		rules: [
  			{
  				test: /\.scss$/,
  				use: [
  					MiniCssExtractPlugin.loader,
  					'css-loader',
  					'sass-loader',
  					{
  						loader: 'style-resources-loader',
  						options: {
  							patterns: [
  								resolve('lib/style/*.scss')
  							]
  						}
  					}
  				]
  			},
  			{
  				test: /\.css$/,
  				use: [
  					MiniCssExtractPlugin.loader,
  					'css-loader'
  				]
  			}
  		]
  	},
  	externals: {
  		react: {
  			commonjs: 'react',
  			commonjs2: 'react',
  			amd: 'react',
  			root: 'React'
  		},
  		'react-dom': {
  			commonjs: 'react-dom',
  			commonjs2: 'react-dom',
  			amd: 'react-dom',
  			root: 'ReactDOM'
  		}
  	},
  	plugins: [
  		new MiniCssExtractPlugin({
  			filename: '[name]_[contenthash:8].css'
  		}),
  		new OptimizeCSSAssetsPlugin({
  			assetNameRegExp: /\.css$/g,
  			cssProcessor: require('cssnano')
  		})
  	]
  });
  