const path = require("path");

const config = {
  // The base directory for resolving the entry option
  resolve: {
    modules: [path.resolve("./node_modules")],
    alias: {
      icons: path.resolve("./src/styles/Icons/assets")
    }
  },

  externals: {
    react: "umd react",
    "react-dom": "umd react-dom",
    "lodash.get": "umd lodash.get",
    "lodash.isequal": "umd lodash.isequal",
    "es6-promise": "umd es6-promise"
  },

  module: {
    rules: [
      // Babel loader, will use your project’s .babelrc
      {
        test: /\.jsx?$/,
        exclude: /node_modules/,
        loader: "babel-loader"
      },

      // Helps importing files
      {
        test: /\.(png|gif|jpg|svg)$/,
        use: [
          {
            loader: "url-loader",
            options: {
              limit: 8192
            }
          }
        ]
      },

      // Fonts
      {
        test: /\.(eot|ttf|woff|woff2)$/,
        loader: "file-loader?name=public/fonts/[name].[ext]"
      },

      {
        test: /\.css$/,
        use: [{ loader: "style-loader" }, { loader: "css-loader" }]
      },

      {
        test: /\.scss$/,
        use: [
          {
            // creates style nodes from JS strings
            loader: "style-loader"
          },
          {
            // translates CSS into CommonJS
            loader: "css-loader",
            options: {
              modules: true,
              localIdentName: "[name]_[local]_[hash:base64:5]",
              sourceMap: true,
              camelCase: true
            }
          },
          {
            // compiles Sass to CSS
            loader: "sass-loader"
          }
        ]
      }
    ]
  }
};

module.exports = config;

@@ -240,204 +240,8 @@
 %7D,%0A%0A
-  externals: %7B%0A    react: %22umd react%22,%0A    %22react-dom%22: %22umd react-dom%22,%0A    %22lodash.get%22: %22umd lodash.get%22,%0A    %22lodash.isequal%22: %22umd lodash.isequal%22,%0A    %22es6-promise%22: %22umd es6-promise%22%0A  %7D,%0A%0A
   mo

Remove externalisation as we need it in the styleguide