|
|
@@ -1,22 +1,26 @@
|
|
|
const HtmlWebPackPlugin = require("html-webpack-plugin");
|
|
|
-const htmlPlugin = new HtmlWebPackPlugin({
|
|
|
- template: "./src/index.html",
|
|
|
- filename: "./index.html"
|
|
|
-});
|
|
|
+const htmlPlugin = new HtmlWebPackPlugin({template: "./src/index.html", filename: "./index.html"});
|
|
|
module.exports = {
|
|
|
-mode: 'development',
|
|
|
- module: {
|
|
|
- rules: [{
|
|
|
- test: /\.js$/,
|
|
|
- exclude: /node_modules/,
|
|
|
- use: {
|
|
|
- loader: "babel-loader"
|
|
|
- }
|
|
|
- },
|
|
|
- {
|
|
|
- test: /\.css$/,
|
|
|
- use: ["style-loader", "css-loader"]
|
|
|
- }
|
|
|
-]},
|
|
|
- plugins: [htmlPlugin]
|
|
|
+ devServer: {
|
|
|
+ allowedHosts: [
|
|
|
+ '.bwlw.uk',
|
|
|
+ 'localhost'
|
|
|
+ ]
|
|
|
+ },
|
|
|
+ mode: 'development',
|
|
|
+ module: {
|
|
|
+ rules: [
|
|
|
+ {
|
|
|
+ test: /\.js$/,
|
|
|
+ exclude: /node_modules/,
|
|
|
+ use: {
|
|
|
+ loader: "babel-loader"
|
|
|
+ }
|
|
|
+ }, {
|
|
|
+ test: /\.css$/,
|
|
|
+ use: ["style-loader", "css-loader"]
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ },
|
|
|
+ plugins: [htmlPlugin]
|
|
|
};
|