debugging 当我午餐chrome debbuger我的断点不可见

ou6hu8tu  于 2023-01-05  发布在  其他
关注(0)|答案(1)|浏览(131)

IDE Visual Studio代码
tsconfig.json

{
  "compileOnSave": false,
  "compilerOptions": {
    "baseUrl": "./",
    "outDir": "./dist/out-tsc",
    "sourceMap": true,
    "declaration": false,
    "downlevelIteration": true,
    "experimentalDecorators": true,
    "moduleResolution": "node",
    "importHelpers": true,
    "target": "ES2022",
    "module": "es2020",
    "resolveJsonModule": true,
    "esModuleInterop": true,
    "lib": [
      "es2018",
      "dom"
    ],
    "useDefineForClassFields": false
  },
  "angularCompilerOptions": {
    "enableI18nLegacyMessageIdFormat": false
  }
}

angular.json

"development": {
              "buildOptimizer": false,
              "optimization": false,
              "vendorChunk": true,
              "extractLicenses": false,
              "sourceMap": true,
              "namedChunks": true
            }

launch.json

{
    "version": "0.2.0",
    "configurations": [
        {
            "type": "chrome",
            "request": "launch",
            "name": "Uruchom przeglądarkę Chrome względem hosta lokalnego",
            "url": "http://localhost:4200",
            "webRoot": "${workspaceFolder}"
        }
    ]
}

sourcemap:真,标准chrome配置,各种各样的东西,静止点是不可到达的。我想调试我的代码之前启动chrome断点是红色的,但启动后,他们是灰色的。

kgqe7b3p

kgqe7b3p1#

ng服务-宿主=127.0.0.1
显式告诉ng在主机www.example.com上运行应用程序127.0.0.1,使调试器无错误运行,并正确读取断点。
Suddenly gets Could not read source map in VSCode using Angular

相关问题