Turning off “Language Service Disabled” error message in VS2017

后端 未结 9 1606
故里飘歌
故里飘歌 2020-12-14 05:53

We are getting the following \"Error\" message in our MVC web application in Visual studio 2017 Enterprise.

The language service is disabled for proje

相关标签:
9条回答
  • 2020-12-14 06:49

    To solve this issue do the following:

    • Create file in root directory of your project and call it tsconfig.json
    • Add this:
    {
      "compilerOptions": {
        "allowJs": true, 
        "noEmit": true, 
        "module": "system",
        "noImplicitAny": true,
        "removeComments": true,
        "preserveConstEnums": true,
        "sourceMap": true
      },
      "include": [
        "scripts"
      ],
      "exclude": [
    
      ],
      "typeAcquisition": {
        "enable": true 
      }
    }
    

    Please have a look at the below two links for tsconfig.json explanation, because you may still need to change it according to your setup. This is the only way that worked for me. I hope that will help.
    https://www.typescriptlang.org/docs/handbook/tsconfig-json.html
    https://developercommunity.visualstudio.com/content/problem/8148/javascript-intellisense-not-working.html

    0 讨论(0)
  • 2020-12-14 06:52

    This helped me. You can have a try.

     Go to Tools -> Options -> Text Editor -> JavaScript/TypeScript -> Language Service -> General
    

    and uncheck the box: "Enable the new JavaScript language service.

    0 讨论(0)
  • 2020-12-14 06:53

    In My case I just disable TypeScript support on Visual Studio:

    Tools > Extensions and Updates > TypeScript for Microsoft Visual Studio > Disable

    After that, just restart Visual Studio, and you are good to go.

    Hope this will help,

    0 讨论(0)
提交回复
热议问题