Skip to content

Commit

Permalink
fix(start): Add Access-Control-Allow-Origin header to dev server (#252
Browse files Browse the repository at this point in the history
)
  • Loading branch information
jxom committed Dec 16, 2021
1 parent 64afabe commit a7e478d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/start.js
Expand Up @@ -37,6 +37,9 @@ module.exports = async (config, callback) => {
// Added to prevent Webpack HMR from breaking when iframeSandbox option is used
// See: https://github.com/webpack/webpack-dev-server/issues/1604
allowedHosts: 'all',
headers: {
'Access-Control-Allow-Origin': '*',
},
};

const compiler = webpack(webpackConfig);
Expand Down

0 comments on commit a7e478d

Please sign in to comment.