title: Angular CLI produces sourcemaps for typescript but browser is only loading style source maps
body: <p>I started in a new Project, and the Team was using Webpack for building its angular application. That Webpack configuration never supported source maps at all. 
  Now we upgraded to Angular 8 and in that turn, we decided to use the Angular-CLI.</p>
  
  <p>The CLI should support Source Maps out of the box, but somehow it is only loading the styles for all components</p>
  
  <p><a href="https://i.stack.imgur.com/pSynT.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/pSynT.png" alt="Chrome dev tools"></a></p>
  
  <p>But whenever i directly check the sourcemaps from the main.js, I can find all the mapped code.</p>
  
  <p>Is it possible, that we missed some config, or some importeted package deactivated the sourcemaps?
  For a new cli project, sourcemaps are working fine</p>
  
  <p>angular.json</p>
  
  <pre><code>{
    "$schema": "./node_modules/@angular/cli/lib/config/schema.json",
    "version": 1,
    "newProjectRoot": "projects",
    "projects": {
      "test2": {
        "projectType": "application",
        "schematics": {
          "@schematics/angular:component": {
            "style": "scss"
          }
        },
        "root": "",
        "sourceRoot": "src",
        "prefix": "unfvor",
        "architect": {
          "build": {
            "builder": "@angular-devkit/build-angular:browser",
            "options": {
              "sourceMap": true,
              "outputPath": "dist/vorschlag",
              "index": "src/index.html",
              "main": "src/main.ts",
              "polyfills": "src/polyfills.ts",
              "tsConfig": "tsconfig.app.json",
              "aot": false,
              "assets": [
                "src/favicon.ico",
                "src/assets"
              ],
              "styles": [
                "src/styles.scss"
              ],
              "scripts": []
            },
            "configurations": {
              "production": {
                "fileReplacements": [
                  {
                    "replace": "src/environments/environment.ts",
                    "with": "src/environments/environment.prod.ts"
                  }
                ],
                "optimization": true,
                "outputHashing": "all",
                "sourceMap": true,
                "extractCss": true,
                "namedChunks": false,
                "aot": true,
                "extractLicenses": true,
                "vendorChunk": false,
                "buildOptimizer": true,
                "budgets": [
                  {
                    "type": "initial",
                    "maximumWarning": "2mb",
                    "maximumError": "5mb"
                  },
                  {
                    "type": "anyComponentStyle",
                    "maximumWarning": "6kb",
                    "maximumError": "10kb"
                  }
                ]
              }
            }
          },
          "serve": {
            "builder": "@angular-devkit/build-angular:dev-server",
            "options": {
              "browserTarget": "test2:build",
              "port": 7002
            },
            "configurations": {
              "production": {
                "browserTarget": "test2:build:production"
              }
            },
          },
          "extract-i18n": {
            "builder": "@angular-devkit/build-angular:extract-i18n",
            "options": {
              "browserTarget": "test2:build"
            }
          },
          "test": {
            "builder": "@angular-devkit/build-angular:karma",
            "options": {
              "main": "src/test.ts",
              "polyfills": "src/polyfills.ts",
              "tsConfig": "tsconfig.spec.json",
              "karmaConfig": "karma.conf.js",
              "assets": [
                "src/favicon.ico",
                "src/assets"
              ],
              "styles": [
                "src/styles.scss"
              ],
              "scripts": []
            }
          },
          "lint": {
            "builder": "@angular-devkit/build-angular:tslint",
            "options": {
              "tsConfig": [
                "tsconfig.app.json",
                "tsconfig.spec.json",
                "e2e/tsconfig.json"
              ],
              "exclude": [
                "**/node_modules/**"
              ]
            }
          },
          "e2e": {
            "builder": "@angular-devkit/build-angular:protractor",
            "options": {
              "protractorConfig": "e2e/protractor.conf.js",
              "devServerTarget": "test2:serve"
            },
            "configurations": {
              "production": {
                "devServerTarget": "test2:serve:production"
              }
            }
          }
        }
      }
    },
    "defaultProject": "vorschlag"
  }
  </code></pre>
  
  <p>tsconfig.app.json</p>
  
  <pre><code>{
    "extends": "./tsconfig.json",
    "compilerOptions": {
      "outDir": "./out-tsc/app",
      "types": []
    },
    "files": [
      "src/main.ts",
      "src/polyfills.ts"
    ],
    "include": [
      "src/**/*.ts"
    ],
    "exclude": [
      "src/test.ts",
      "src/**/*.spec.ts"
    ]
  }
  </code></pre>
  
  <p>tsconfig.json</p>
  
  <pre><code>{
    "compileOnSave": false,
    "compilerOptions": {
      "baseUrl": "./",
      "outDir": "./dist/out-tsc",
      "sourceMap": true,
      "declaration": false,
      "downlevelIteration": true,
      "experimentalDecorators": true,
      "module": "esnext",
      "moduleResolution": "node",
      "allowSyntheticDefaultImports": true,
      "importHelpers": true,
      "target": "es2015",
      "typeRoots": [
        "node_modules/@types"
      ],
      "lib": [
        "es2018",
        "dom",
        "esnext"
      ]
    },
    "angularCompilerOptions": {
      "fullTemplateTypeCheck": true,
      "strictInjectionParameters": true
    }
  }
  </code></pre>