title: Upgraded from angular 5 to angular 8, issues with SystemJS
body: <p>I have an app made in ASP.Net MVC with Angular 5 inside to display the views. I updated Angular from 5 to 8 and now I am having a big trouble to make it work because this error:</p>
  
  <p><a href="https://i.stack.imgur.com/ifm1n.png" rel="nofollow noreferrer">error image</a></p>
  
  <p>It seems something about SystemJS or Zone.js</p>
  
  <p>I also have watched in the dev tools if some file is not loading correctly, but everything seems ok.</p>
  
  <p>I don't know what is the problem here, so I can not resolve it myself, thanks in advance for the help you may give.</p>
  
  <p>My package.json:</p>
  
  <pre class="lang-js prettyprint-override"><code>{
    "name": "App",
    "version": "1.0.0",
    "private": true,
    "description": "App package.json",
    "scripts": {
      "ng": "ng",
      "build": "ng build --prod",
      "start": "ng serve",
      "test": "ng test",
      "i18n": "ng-xi18n",
      "lint": "tslint ./src/**/*.ts -t verbose"
    },
    "keywords": [],
    "author": "",
    "license": "MIT",
    "dependencies": {
      "@angular/common": "^8.2.0",
      "@angular/compiler": "^8.2.0",
      "@angular/core": "^8.2.0",
      "@angular/forms": "^8.2.0",
      "@angular/platform-browser": "^8.2.0",
      "@angular/platform-browser-dynamic": "^8.2.0",
      "@angular/platform-server": "^8.2.0",
      "@angular/router": "^8.2.0",
      "@angular/upgrade": "^8.2.0",
      "@ng-bootstrap/ng-bootstrap": "^5.1.0",
      "core-js": "^3.1.4",
      "dexie": "~2.0.4",
      "file-saver": "^2.0.2",
      "minimatch": "~3.0.4",
      "ngx-toastr": "^10.0.4",
      "performance-now": "^2.1.0",
      "rxjs": "^6.5.2",
      "rxjs-compat": "^6.5.2",
      "systemjs": "^0.21.5",
      "text-encoding": "^0.7.0",
      "zone.js": "^0.9.1"
    },
    "devDependencies": {
      "@angular/animations": "^8.2.0",
      "@angular/cli": "^8.2.0",
      "@angular/compiler-cli": "^8.2.0",
      "@types/file-saver": "^2.0.1",
      "@types/google.analytics": "^0.0.40",
      "@types/jasmine": "^3.3.16",
      "@types/jasminewd2": "^2.0.6",
      "@types/node": "^12.6.9",
      "jasmine-core": "^3.4.0",
      "jasmine-spec-reporter": "^4.2.1",
      "karma": "^4.2.0",
      "karma-chrome-launcher": "^3.0.0",
      "karma-cli": "^2.0.0",
      "karma-coverage-istanbul-reporter": "^2.1.0",
      "karma-jasmine": "^2.0.1",
      "karma-jasmine-html-reporter": "^1.4.2",
      "karma-phantomjs-launcher": "^1.0.4",
      "lodash": "^4.17.15",
      "phantomjs-prebuilt": "^2.1.16",
      "protractor": "^5.4.2",
      "ts-node": "^8.3.0",
      "tslint": "^5.18.0",
      "typescript": "^3.5.3"
    },
    "repository": {},
    "main": "karma-test-shim.js"
  }
  </code></pre>
  
  <p>My systemjs.config.js:</p>
  
  
  
  <pre class="lang-js prettyprint-override"><code>/**
   * System configuration for Angular.
   */
  (function (global) {
      System.config({
          paths: {
              // paths serve as alias
              'npm:': 'Js/angular/node_modules/'
          },
          // map tells the System loader where to look for things
          map: {
              // our app is within the app folder
              app: 'Js/angular/src/app',
  
              src: 'Js/angular/src',
  
              // angular bundles
              '@angular/core': 'npm:@angular/core/bundles/core.umd.js',
              '@angular/common': 'npm:@angular/common/bundles/common.umd.js',
              '@angular/common/http': 'npm:@angular/common/bundles/common-http.umd.js',
              '@angular/compiler': 'npm:@angular/compiler/bundles/compiler.umd.js',
              '@angular/platform-browser': 'npm:@angular/platform-browser/bundles/platform-browser.umd.js',
              '@angular/platform-browser-dynamic': 'npm:@angular/platform-browser-dynamic/bundles/platform-browser-dynamic.umd.js',
              '@angular/router': 'npm:@angular/router/bundles/router.umd.js',
              '@angular/forms': 'npm:@angular/forms/bundles/forms.umd.js',
  
              // other libraries                        
              '@ng-bootstrap/ng-bootstrap': 'npm:@ng-bootstrap/ng-bootstrap/bundles/ng-bootstrap.umd.js',
              'rxjs': 'npm:rxjs',
              'tslib': 'npm:tslib/tslib.js',
              'dexie': 'npm:dexie/dist/dexie.js',
              'file-saver': 'npm:file-saver/dist/FileSaver.min.js',
              'text-encoding': 'npm:text-encoding/lib/encoding.js'
          },
          // packages tells the System loader how to load when no filename and/or no extension
          packages: {
              src: {
                  main: 'Js/angular/src/main.js',
                  defaultExtension: 'js'
              },
              rxjs: {
                  main: 'index.js',
                  defaultExtension: 'js'
              },
              'rxjs/operators': {
                  main: 'index.js',
                  defaultExtension: 'js'
              },
              'dexie': {
                  format: 'amd'
              },
              'file-saver': {
                  format: 'global'
              }
          }
      });
  })(this);
  </code></pre>
  
  <p>Bundle concerning angular (App_Start/BundleConfig.cs):</p>
  
  
  
  <pre class="lang-js prettyprint-override"><code>bundles.Add(new ScriptBundle("~/bundles/angular").Include(
                          "~/Js/angular/node_modules/core-js/client/shim.min.js",
                          "~/Js/angular/node_modules/zone.js/dist/zone.js",
                          "~/Js/angular/node_modules/systemjs/dist/system.src.js",
                          "~/Js/angular/src/systemjs.config.js"));
  </code></pre>