Skip to content

Commit

Permalink
for serve command, write build to disk and rewrite sourcemaps so vsco…
Browse files Browse the repository at this point in the history
…de can load the files for debugging
  • Loading branch information
BogdanDenis committed Feb 7, 2024
1 parent cb26063 commit b7c3aad
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion webpack.config.cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ module.exports = {
filename: 'bundle.[name][contenthash].js',
chunkFilename: 'chunk.[name][chunkhash].js',
publicPath: '/',
clean: true
clean: true,
devtoolModuleFilenameTemplate: 'file:///[absolute-resource-path]' // map to source with absolute file path not webpack:// protocol
},
};
1 change: 1 addition & 0 deletions webpack/serve.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ module.exports = function serve(stripesConfig, options) {
app.use(webpackDevMiddleware(compiler, {
stats: 'errors-only',
publicPath: config.output.publicPath,
writeToDisk: true,
}));

app.use(webpackHotMiddleware(compiler));
Expand Down

0 comments on commit b7c3aad

Please sign in to comment.