Visual Studio Code Automatic Imports

前端 未结 12 1309
轻奢々
轻奢々 2020-12-02 11:00

I\'m in the process of making the move from Webstorm to Visual Studio Code. The Performance in Webstorm is abysmal.

Visual studio code isn\'t being very helpful abo

12条回答
  •  孤街浪徒
    2020-12-02 11:36

    In the tsconfig.app.json, a standard Angular 10 app has:

    {
      "extends": "./tsconfig.base.json",
      "compilerOptions": {
        "outDir": "./out-tsc/app",
        "types": []
      },
      "files": [
        "src/main.ts",
        "src/polyfills.ts"
      ],
      "include": [
        "src/**/*.d.ts"
      ]
    }
    

    Once I changed the include like to be:

      "include": [
        "src/**/*.d.ts",
        "src/**/*.ts"
      ]
    

    It worked for me

提交回复
热议问题