当针对core50时,防止intellisense抱怨dnx451

时间:2016-04-13 20:43:45

标签: asp.net-core visual-studio-code .net-core

代码抱怨说:

  

类型或命名空间名称' AspNetCore'在命名空间中不存在' Microsoft' ...

The intellisense is targeting 451.

这是我们的project.json文件。

{
    "dependencies": {
        "Microsoft.AspNetCore.Mvc.Core": "1.0.0-*"
    },
    "frameworks": {
        "netstandardapp1.5": {
            "imports": [
                "dnxcore50"
            ],
            "dependencies": {
                "NETStandard.Library": "1.5.0-*"
            }
        }
    }
}

这是我们的dotnet build输出。

> dotnet build
Compiling VsCodeIntellisense for .NETStandardApp,Version=v1.5

Compilation succeeded.
    0 Warning(s)
    0 Error(s)

Time elapsed 00:00:01.5669579

1 个答案:

答案 0 :(得分:0)

Upgrading to the most resent version of vscode appears to have fixed this.

相关问题