feat(webpack): When using the HTML5 History API, the index.html page will likely have to be served in place of any 404 responses. Enable devServer.historyApiFallback by setting it to true.

This commit is contained in:
dancingCycle 2023-06-26 05:50:45 +02:00
parent 023c002b2a
commit a8d96fbeaa
1 changed files with 2 additions and 0 deletions

View File

@ -10,5 +10,7 @@ module.exports = merge(common, {
devtool: 'inline-source-map',
devServer: {
static: path.resolve(__dirname, '../dist'),
//When using the HTML5 History API, the index.html page will likely have to be served in place of any 404 responses. Enable devServer.historyApiFallback by setting it to true.
historyApiFallback: true,
},
});