var baseConfig = require('./webpackBaseConfig')
var ExtractTextPlugin = require('extract-text-webpack-plugin')
var path = require('path')

module.exports = [Object.assign({}, baseConfig, {
  plugins: baseConfig.plugins.concat([
    new ExtractTextPlugin('[name].css')
  ]),
  devtool: 'source-map'
}), {
  devtool: 'source-map',
  entry: {
    htmlExport: path.join(__dirname, 'public/js/htmlExport.js')
  },
  module: {
    loaders: [{
      test: /\.css$/,
      loader: ExtractTextPlugin.extract('style-loader', 'css-loader')
    }, {
      test: /\.scss$/,
      loader: ExtractTextPlugin.extract('style-loader', 'sass-loader')
    }, {
      test: /\.less$/,
      loader: ExtractTextPlugin.extract('style-loader', 'less-loader')
    }]
  },
  output: {
    path: path.join(__dirname, 'public/build'),
    publicPath: '/build/',
    filename: '[name].js'
  },
  plugins: [
    new ExtractTextPlugin('html.min.css')
  ]
}]

@@ -45,23 +45,28 @@
 g')%0A
-var 
+const MiniCss
 Extract
-Text
 Plug
@@ -83,28 +83,24 @@
 re('
-extract-text-webpack
+mini-css-extract
 -plu
@@ -234,39 +234,100 @@
 new 
+MiniCss
 Extract
-Text
 Plugin(
-'%5Bname%5D.css')
+%7B%0A      filename: '%5Bname%5D.css',%0A      chunkFilename: '%5Bid%5D.css'%0A    %7D)%0A
 %0A  %5D
@@ -480,22 +480,20 @@
 : %7B%0A    
-loader
+rule
 s: %5B%7B%0A  
@@ -522,42 +522,14 @@
     
-loader: ExtractTextPlugin.extract(
+use: %5B
 'sty
@@ -544,33 +544,33 @@
 r', 'css-loader'
-)
+%5D
 %0A    %7D, %7B%0A      
@@ -596,42 +596,14 @@
     
-loader: ExtractTextPlugin.extract(
+use: %5B
 'sty
@@ -623,25 +623,25 @@
 sass-loader'
-)
+%5D
 %0A    %7D, %7B%0A  
@@ -671,42 +671,14 @@
     
-loader: ExtractTextPlugin.extract(
+use: %5B
 'sty
@@ -702,17 +702,17 @@
 -loader'
-)
+%5D
 %0A    %7D%5D%0A
@@ -859,26 +859,47 @@
 new 
+MiniCss
 Extract
-Text
 Plugin(
+%7B%0A      filename: 
 'htm
@@ -908,16 +908,22 @@
 min.css'
+%0A    %7D
 )%0A  %5D%0A%7D%5D

Upgrade to Webpack 4 - development config