Commit e3743181 authored by Artak Mkrtchyan's avatar Artak Mkrtchyan
Browse files

Upgraded to 5.0-rc2

parent fddeba9b
<Project>
<PropertyGroup>
<AspNetCoreVersion>5.0.0-preview.7.20326.3</AspNetCoreVersion>
<BlazorVersion>5.0.0-preview.7.20326.3</BlazorVersion>
<EntityFrameworkVersion>5.0.0-preview.7.20326.1</EntityFrameworkVersion>
<SystemNetHttpJsonVersion>5.0.0-preview.7.20326.1</SystemNetHttpJsonVersion>
<AspNetCoreVersion>5.0.0-rc.2.*</AspNetCoreVersion>
<BlazorVersion>5.0.0-rc.2.*</BlazorVersion>
<EntityFrameworkVersion>5.0.0-rc.2.*</EntityFrameworkVersion>
<SystemNetHttpJsonVersion>5.0.0-rc.2.*</SystemNetHttpJsonVersion>
</PropertyGroup>
</Project>
<CascadingAuthenticationState>
<Router AppAssembly="typeof(Program).Assembly" Context="routeData">
<Found>
<AuthorizeRouteView RouteData="routeData" DefaultLayout="typeof(MainLayout)">
<Router AppAssembly="typeof(Program).Assembly">
<Found Context="routeData">
<AuthorizeRouteView RouteData="@routeData" DefaultLayout="@typeof(MainLayout)">
<NotAuthorized>
<RedirectToLogin />
</NotAuthorized>
......
<Project Sdk="Microsoft.NET.Sdk.Web">
<Project Sdk="Microsoft.NET.Sdk.BlazorWebAssembly">
<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<RuntimeIdentifier>browser-wasm</RuntimeIdentifier>
<UseBlazorWebAssembly>true</UseBlazorWebAssembly>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="$(BlazorVersion)" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="$(BlazorVersion)" PrivateAssets="all" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.Authentication" Version="$(BlazorVersion)" />
<PackageReference Include="Microsoft.Extensions.Http" Version="$(SystemNetHttpJsonVersion)" />
<PackageReference Include="System.Net.Http.Json" Version="$(SystemNetHttpJsonVersion)" />
......
......@@ -12,7 +12,7 @@ namespace BlazingPizza.Client
public static async Task Main(string[] args)
{
var builder = WebAssemblyHostBuilder.CreateDefault(args);
builder.RootComponents.Add<App>("app");
builder.RootComponents.Add<App>("#app");
builder.Services.AddScoped(sp => new HttpClient { BaseAddress = new Uri(builder.HostEnvironment.BaseAddress) });
builder.Services.AddHttpClient<OrdersClient>(client => client.BaseAddress = new Uri(builder.HostEnvironment.BaseAddress))
......
......@@ -12,9 +12,7 @@
<title>Blazing Pizza</title>
</head>
<body>
<app>
<div class="loading-bar"></div>
</app>
<div id="app" class="loading-bar"></div>
<div id="blazor-error-ui">
An unhandled error has occurred.
......
......@@ -8,5 +8,7 @@
<PackageReference Include="Microsoft.AspNetCore.Components" Version="$(AspNetCoreVersion)" />
<PackageReference Include="Microsoft.AspNetCore.Components.Web" Version="$(AspNetCoreVersion)" />
</ItemGroup>
<ItemGroup>
<SupportedPlatform Include="browser" />
</ItemGroup>
</Project>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment