Browse Source

webpack: dev server doesn't find webpack.html if we set a public path

JC Brand 5 years ago
parent
commit
b26e1c87ae
3 changed files with 2 additions and 1 deletions
  1. 0 1
      webpack.common.js
  2. 1 0
      webpack.dev.js
  3. 1 0
      webpack.prod.js

+ 0 - 1
webpack.common.js

@@ -5,7 +5,6 @@ const webpack = require('webpack');
 module.exports = {
     output: {
         path: path.resolve(__dirname, 'dist'), // Output path for generated bundles
-        publicPath: '/dist/', // URL base path for all assets
         chunkFilename: '[name].js'
     },
     entry: path.resolve(__dirname, 'src/converse.js'),

+ 1 - 0
webpack.dev.js

@@ -5,6 +5,7 @@ const MiniCssExtractPlugin = require('mini-css-extract-plugin');
 
 module.exports = merge(prod, {
     output: {
+        publicPath: '/dist/', // URL base path for all assets
         filename: 'converse.js',
     },
     optimization: {

+ 1 - 0
webpack.prod.js

@@ -6,6 +6,7 @@ const MiniCssExtractPlugin = require('mini-css-extract-plugin');
 
 module.exports = merge(common, {
     output: {
+        publicPath: '/dist/', // URL base path for all assets
         filename: 'converse.min.js',
     },
     plugins: [