diff --git a/aio/content/examples/upgrade-phonecat-1-typescript/karma.conf.ajs.js b/aio/content/examples/upgrade-phonecat-1-typescript/karma.conf.ajs.js index dc829d1983..89d9e7bcd7 100644 --- a/aio/content/examples/upgrade-phonecat-1-typescript/karma.conf.ajs.js +++ b/aio/content/examples/upgrade-phonecat-1-typescript/karma.conf.ajs.js @@ -16,6 +16,15 @@ module.exports = function(config) { '**/*.spec.js' ], + // This is needed, because the AngularJS files are loaded from `https://code.angularjs.org/`. + // Without this, latest browsers prevent loading the scripts from localhost with: + // ``` + // Access to script at 'https://code.angularjs.org/1.5.5/angular.js' from origin + // 'http://localhost:9876' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' + // header is present on the requested resource. + // ``` + crossOriginAttribute: false, + autoWatch: true, frameworks: ['jasmine'], diff --git a/aio/content/examples/upgrade-phonecat-2-hybrid/karma.conf.ajs.js b/aio/content/examples/upgrade-phonecat-2-hybrid/karma.conf.ajs.js index 213834b1aa..699b5075f7 100644 --- a/aio/content/examples/upgrade-phonecat-2-hybrid/karma.conf.ajs.js +++ b/aio/content/examples/upgrade-phonecat-2-hybrid/karma.conf.ajs.js @@ -44,12 +44,21 @@ module.exports = function(config) { // #enddocregion files ], + // This is needed, because the AngularJS files are loaded from `https://code.angularjs.org/`. + // Without this, latest browsers prevent loading the scripts from localhost with: + // ``` + // Access to script at 'https://code.angularjs.org/1.5.5/angular.js' from origin + // 'http://localhost:9876' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' + // header is present on the requested resource. + // ``` + crossOriginAttribute: false, + // #docregion html // proxied base paths for loading assets proxies: { // required for component assets fetched by Angular's compiler - "/phone-detail": '/base/app/phone-detail', - "/phone-list": '/base/app/phone-list' + '/phone-detail': '/base/app/phone-detail', + '/phone-list': '/base/app/phone-list' }, // #enddocregion html