text: const HtmlWebPackPlugin = require("html-webpack-plugin");
  const path = require("path");
  const Dotenv = require("dotenv-webpack");
  
  const htmlWebpackPlugin = new HtmlWebPackPlugin({
    template: "./src/index.html",
    filename: "./index.html"
  });
  
  module.exports = {
    module: {
      rules: [
        {
          test: /\.js$/,
          exclude: /node_modules/,
          use: {
            loader: "babel-loader"
          }
        },
        {
          test: /\.scss$/,
          use: ["style-loader", "css-loader", "sass-loader"]
        },
        {
          test: /\.css$/,
          use: [
            {
              loader: "style-loader"
            },
            {
              loader: "css-loader",
              options: {
                modules: true,
                importLoaders: 1,
                localIdentName: "[name]_[local]_[hash:base64]",
                sourceMap: true
                //   minimize: true
              }
            }
          ]
        },
        {
          test: /\.(jpe?g|png|gif)$/,
          use: [
            {
              loader: "url-loader",
              options: {
                limit: 10000
              }
            }
          ]
        },
        {
          test: /\.(eot|svg|ttf|woff2?|otf)$/,
          use: "file-loader"
        }
      ]
    },
    plugins: [htmlWebpackPlugin, new Dotenv()],
    devtool: "cheap-module-eval-source-map",
    devServer: {
      contentBase: path.join(__dirname, "src"),
      historyApiFallback: true
    }
    //   target: "node"
  };
  