changes to wasm template per Dan Roth

This commit is contained in:
Isaac Levin 2019-07-08 14:46:07 -04:00
parent 592bb681d1
commit 900c6adff9
9 changed files with 9 additions and 114 deletions

View File

@ -1,30 +0,0 @@
{
"$schema": "http://json.schemastore.org/vs-2017.3.host",
"name": {
"text": "Blazor (ASP.NET Core hosted)",
"id": "1050"
},
"description": {
"text": "A project template for creating a Blazor application that runs on WebAssembly and is hosted on an ASP.NET Core server.",
"package": "{0CD94836-1526-4E85-87D3-FB5274C5AFC9}",
"id": "1051"
},
"order": 610,
"icon": "icon.png",
"learnMoreLink": "https://github.com/aspnet/blazor",
"uiFilters": [
"oneaspnet"
],
"additionalWizardParameters": {
"$isMultiProjectTemplate$": "true"
},
"symbolInfo": [
{
"id": "Hosted",
"name": {
"text": "_Hosted"
},
"isVisible": "true"
}
]
}

View File

@ -1,64 +0,0 @@
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.0.0
MinimumVisualStudioVersion = 16.0.0.0
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BlazorHosted-CSharp.Server", "Server\BlazorHosted-CSharp.Server.csproj", "{650B3CE7-2E93-4CC4-9F46-466686815EAA}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BlazorHosted-CSharp.Client", "Client\BlazorHosted-CSharp.Client.csproj", "{5990939C-7E7B-4CFA-86FF-44CA5756498A}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BlazorHosted-CSharp.Shared", "Shared\BlazorHosted-CSharp.Shared.csproj", "{0AFFA7FD-4E37-4636-AB91-3753E746DB98}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Debug|x64 = Debug|x64
Debug|x86 = Debug|x86
Release|Any CPU = Release|Any CPU
Release|x64 = Release|x64
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{5990939C-7E7B-4CFA-86FF-44CA5756498A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{5990939C-7E7B-4CFA-86FF-44CA5756498A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{5990939C-7E7B-4CFA-86FF-44CA5756498A}.Debug|x64.ActiveCfg = Debug|Any CPU
{5990939C-7E7B-4CFA-86FF-44CA5756498A}.Debug|x64.Build.0 = Debug|Any CPU
{5990939C-7E7B-4CFA-86FF-44CA5756498A}.Debug|x86.ActiveCfg = Debug|Any CPU
{5990939C-7E7B-4CFA-86FF-44CA5756498A}.Debug|x86.Build.0 = Debug|Any CPU
{5990939C-7E7B-4CFA-86FF-44CA5756498A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{5990939C-7E7B-4CFA-86FF-44CA5756498A}.Release|Any CPU.Build.0 = Release|Any CPU
{5990939C-7E7B-4CFA-86FF-44CA5756498A}.Release|x64.ActiveCfg = Release|Any CPU
{5990939C-7E7B-4CFA-86FF-44CA5756498A}.Release|x64.Build.0 = Release|Any CPU
{5990939C-7E7B-4CFA-86FF-44CA5756498A}.Release|x86.ActiveCfg = Release|Any CPU
{5990939C-7E7B-4CFA-86FF-44CA5756498A}.Release|x86.Build.0 = Release|Any CPU
{650B3CE7-2E93-4CC4-9F46-466686815EAA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{650B3CE7-2E93-4CC4-9F46-466686815EAA}.Debug|Any CPU.Build.0 = Debug|Any CPU
{650B3CE7-2E93-4CC4-9F46-466686815EAA}.Debug|x64.ActiveCfg = Debug|Any CPU
{650B3CE7-2E93-4CC4-9F46-466686815EAA}.Debug|x64.Build.0 = Debug|Any CPU
{650B3CE7-2E93-4CC4-9F46-466686815EAA}.Debug|x86.ActiveCfg = Debug|Any CPU
{650B3CE7-2E93-4CC4-9F46-466686815EAA}.Debug|x86.Build.0 = Debug|Any CPU
{650B3CE7-2E93-4CC4-9F46-466686815EAA}.Release|Any CPU.ActiveCfg = Release|Any CPU
{650B3CE7-2E93-4CC4-9F46-466686815EAA}.Release|Any CPU.Build.0 = Release|Any CPU
{650B3CE7-2E93-4CC4-9F46-466686815EAA}.Release|x64.ActiveCfg = Release|Any CPU
{650B3CE7-2E93-4CC4-9F46-466686815EAA}.Release|x64.Build.0 = Release|Any CPU
{650B3CE7-2E93-4CC4-9F46-466686815EAA}.Release|x86.ActiveCfg = Release|Any CPU
{650B3CE7-2E93-4CC4-9F46-466686815EAA}.Release|x86.Build.0 = Release|Any CPU
{0AFFA7FD-4E37-4636-AB91-3753E746DB98}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{0AFFA7FD-4E37-4636-AB91-3753E746DB98}.Debug|Any CPU.Build.0 = Debug|Any CPU
{0AFFA7FD-4E37-4636-AB91-3753E746DB98}.Debug|x64.ActiveCfg = Debug|Any CPU
{0AFFA7FD-4E37-4636-AB91-3753E746DB98}.Debug|x64.Build.0 = Debug|Any CPU
{0AFFA7FD-4E37-4636-AB91-3753E746DB98}.Debug|x86.ActiveCfg = Debug|Any CPU
{0AFFA7FD-4E37-4636-AB91-3753E746DB98}.Debug|x86.Build.0 = Debug|Any CPU
{0AFFA7FD-4E37-4636-AB91-3753E746DB98}.Release|Any CPU.ActiveCfg = Release|Any CPU
{0AFFA7FD-4E37-4636-AB91-3753E746DB98}.Release|Any CPU.Build.0 = Release|Any CPU
{0AFFA7FD-4E37-4636-AB91-3753E746DB98}.Release|x64.ActiveCfg = Release|Any CPU
{0AFFA7FD-4E37-4636-AB91-3753E746DB98}.Release|x64.Build.0 = Release|Any CPU
{0AFFA7FD-4E37-4636-AB91-3753E746DB98}.Release|x86.ActiveCfg = Release|Any CPU
{0AFFA7FD-4E37-4636-AB91-3753E746DB98}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {4C26868E-5E7C-458D-82E3-040509D0C71F}
EndGlobalSection
EndGlobal

View File

@ -1,12 +0,0 @@
@using System.Net.Http
@using Microsoft.AspNetCore.Components.Forms
@using Microsoft.AspNetCore.Components.Layouts
@using Microsoft.AspNetCore.Components.Routing
@using Microsoft.JSInterop
@*#if (!Hosted)
@using BlazorHosted_CSharp
@using BlazorHosted_CSharp.Shared
#else
@using BlazorHosted_CSharp.Client
@using BlazorHosted_CSharp.Client.Shared
#endif*@

View File

@ -36,7 +36,7 @@
{
"condition": "(Hosted && HostIdentifier != \"dotnetcli\" && HostIdentifier != \"dotnetcli-preview\")",
"path": "Shared/BlazorWasm-CSharp.Shared.csproj"
}
}
],
"shortName": "blazorwasm",
"sourceName": "BlazorWasm-CSharp",

View File

@ -1,11 +1,11 @@
{
"$schema": "http://json.schemastore.org/vs-2017.3.host",
"name": {
"text": "Blazor WebAssembly App",
"text": "Blazor (ASP.NET Core hosted)",
"id": "1050"
},
"description": {
"text": "A project template for creating a Blazor app that runs on WebAssembly and is optionally hosted by an ASP.NET Core app. This template can be used for web apps with rich dynamic user interfaces (UIs).",
"text": "A project template for creating a Blazor application that runs on WebAssembly and is hosted on an ASP.NET Core server.",
"package": "{0CD94836-1526-4E85-87D3-FB5274C5AFC9}",
"id": "1051"
},
@ -22,7 +22,7 @@
{
"id": "Hosted",
"name": {
"text": "ASP.NET Core _hosted"
"text": "_Hosted"
},
"isVisible": "true"
}

View File

@ -12,7 +12,7 @@
<PackageReference Include="Microsoft.AspNetCore.Blazor.Build" Version="$(TemplateBlazorPackageVersion)" PrivateAssets="all" />
<PackageReference Include="Microsoft.AspNetCore.Blazor.HttpClient" Version="$(TemplateBlazorPackageVersion)" />
<PackageReference Include="Microsoft.AspNetCore.Blazor.DevServer" Version="$(TemplateBlazorPackageVersion)" PrivateAssets="all" />
<PackageReference Include="Microsoft.AspNetCore.Blazor.DevServer" Version="$(TemplateBlazorPackageVersion)" PrivateAssets="all" />
</ItemGroup>
</ItemGroup>
<!--#if Hosted -->
<ItemGroup>

View File

@ -4,7 +4,7 @@
<p>Current count: @currentCount</p>
<button class="btn btn-primary" @onclick="@IncrementCount">Click me</button>
<button class="btn btn-primary" @onclick="IncrementCount">Click me</button>
@code {
int currentCount = 0;

View File

@ -5,7 +5,7 @@
</button>
</div>
<div class="@NavMenuCssClass" @onclick="@ToggleNavMenu">
<div class="@NavMenuCssClass" @onclick="ToggleNavMenu">
<ul class="nav flex-column">
<li class="nav-item px-3">
<NavLink class="nav-link" href="" Match="NavLinkMatch.All">

View File

@ -1,5 +1,6 @@
@using System.Net.Http
@using System.Net.Http
@using Microsoft.AspNetCore.Components.Forms
@using Microsoft.AspNetCore.Components.Layouts
@using Microsoft.AspNetCore.Components.Routing
@using Microsoft.JSInterop
@*#if (!Hosted)