Reputation: 364
I have what I think is a fully up-to-date installation of Visual Studio 2015 Update 3.
If I create a new solution using the "ASP.NET Core Web Application (.NET Core)" template, then select the "Web Application" ASP.NET Core Template with "No Authentication" and wait for it to finish restoring packages, then viewing Razor source files with Tag Helpers shows them in bold purple. A good example is Views\Shared_Layout.cshtml:
However, if I attempt to upgrade it to .NET Core 1.1 following the instructions at the .NET Web Development and Tools Blog then the design-time TagHelper support is lost:
Also missing is all TagHelper Intellisense.
I have SDK version 1.0.0-preview2-1-003177 installed and referenced in the global.json:
{
"projects": [ "src", "test" ],
"sdk": {
"version": "1.0.0-preview2-1-003177"
}
}
And the project.json looks like this:
{
"dependencies": {
"Microsoft.NETCore.App": {
"version": "1.1.0",
"type": "platform"
},
"Microsoft.AspNetCore.Diagnostics": "1.1.0",
"Microsoft.AspNetCore.Mvc": "1.1.0",
"Microsoft.AspNetCore.Razor.Tools": {
"version": "1.1.0-preview4-final",
"type": "build"
},
"Microsoft.AspNetCore.Routing": "1.1.0",
"Microsoft.AspNetCore.Server.IISIntegration": "1.1.0",
"Microsoft.AspNetCore.Server.Kestrel": "1.1.0",
"Microsoft.AspNetCore.StaticFiles": "1.1.0",
"Microsoft.Extensions.Configuration.EnvironmentVariables": "1.1.0",
"Microsoft.Extensions.Configuration.Json": "1.1.0",
"Microsoft.Extensions.Logging": "1.1.0",
"Microsoft.Extensions.Logging.Console": "1.1.0",
"Microsoft.Extensions.Logging.Debug": "1.1.0",
"Microsoft.Extensions.Options.ConfigurationExtensions": "1.1.0",
"Microsoft.VisualStudio.Web.BrowserLink.Loader": "14.1.0"
},
"tools": {
"BundlerMinifier.Core": "2.0.238",
"Microsoft.AspNetCore.Razor.Tools": "1.1.0-preview4-final",
"Microsoft.AspNetCore.Server.IISIntegration.Tools": "1.1.0-preview4-final"
},
"frameworks": {
"netcoreapp1.1": {
"imports": [
"dnxcore50"
]
}
},
"buildOptions": {
"emitEntryPoint": true,
"preserveCompilationContext": true
},
"runtimeOptions": {
"configProperties": {
"System.GC.Server": true
}
},
"publishOptions": {
"include": [
"wwwroot",
"**/*.cshtml",
"appsettings.json",
"web.config"
]
},
"scripts": {
"prepublish": [ "bower install", "dotnet bundle" ],
"postpublish": [ "dotnet publish-iis --publish-folder %publish:OutputPath% --framework %publish:FullTargetFramework%" ]
}
}
So, what am I missing?
I see there is a similar Issue against the Razor tooling at Github
Razor Tag Intellisense disappears
I do hope there is a resolution...
Upvotes: 0
Views: 102
Reputation: 364
I came in the morning and the demo project was working as expected. After some head-scratching, I think it's because I forgot to clean and re-build my demo project. I may look like a doofus, but it's a salutatory tale so I'm leaving it here for posterity.
For the record, you certainly do need to reference the Razor tooling twice in project.json:
"dependencies": {
"Microsoft.AspNetCore.Razor.Tools": {
"version": "1.1.0-preview4-final",
"type": "build"
}
},
"tools": {
"Microsoft.AspNetCore.Razor.Tools": "1.1.0-preview4-final"
}
:slinks off in shame.
Upvotes: 1