Skip to content

Commit

Permalink
fix(@angular-devkit/build-angular): fixes cors issues with karma (#11970
Browse files Browse the repository at this point in the history
)

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
alan-agius4 authored and vikerman committed Aug 28, 2018

Unverified

The committer email address is not verified.
1 parent 3f94b2d commit 7f67c64
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
@@ -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 {

0 comments on commit 7f67c64

Please sign in to comment.