fix(@angular-devkit/build-angular): fixes cors issues with karma (#11970)

Checking the stack trace in the issue one can noticed that the paths for the components are being served via the `webpack://` protocol which is causing a `cors` issue between `http` and `webpack` protocol

This PR removed the `webpack` protocol from the `devtoolModuleFilenameTemplate`

Closes #11966
This commit is contained in:
Alan Agius 2018-08-28 22:10:43 +02:00 committed by vikerman
parent 3f94b2d8ba
commit 7f67c64be1

View File

@ -144,6 +144,7 @@ const init: any = (config: any, emitter: any, customFileHandlers: any) => {
// Files need to be served from a custom path for Karma.
webpackConfig.output.path = '/_karma_webpack_/';
webpackConfig.output.publicPath = '/_karma_webpack_/';
webpackConfig.output.devtoolModuleFilenameTemplate = '[namespace]/[resource-path]?[loaders]';
let compiler: any;
try {