Browse Source

add `dev` script to package.json

les 4 years ago
parent
commit
6a35503ba1
2 changed files with 6 additions and 0 deletions
  1. 2 0
      package.json
  2. 4 0
      webpack.config.js

+ 2 - 0
package.json

@@ -58,6 +58,8 @@
     "web-audio-buffer-queue": "^1.1.0",
     "webpack": "^4.44.2",
     "webpack-cli": "^3.3.12",
+    "webpack": "^4.42.1",
+    "webpack-cli": "^3.3.11",
     "worker-loader": "^2.0.0"
   },
   "optionalDependencies": {}

+ 4 - 0
webpack.config.js

@@ -12,6 +12,10 @@ module.exports = {
     theme: './app/theme.js',
     matrix: './app/matrix.js'
   },
+  devServer: {
+    contentBase: './dist',
+    hot: true
+  },
   devtool: "cheap-source-map",
   output: {
     path: path.join(__dirname, 'dist'),