-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Upgrade to .NET 6 #330
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Upgrade to .NET 6 #330
Changes from 17 commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
8fcb170
upgrade to .net 6
sayedihashimi 79a0472
updating to rc2
sayedihashimi d269b71
adding gitignore to ignore sqllite temp files
sayedihashimi 10d6596
removing invalid code that i added on accident
sayedihashimi 0ee662f
going back to a different rc2 build that works w Hot Reload
sayedihashimi 998ca63
removing invalid code that i added on accident
sayedihashimi 70ebe01
Started TFM variable
csharpfritz 9153460
Updated all projects to NET6 and Duende IdentityFramework
csharpfritz 08ce819
Upgraded finished project to .NET 6 with C# 10 features
csharpfritz a546467
Finished savepoint 0 and 1
csharpfritz 2ef4196
Updated savepoint 2, 3, 4, 5, 6, 7, 8, 9
csharpfritz 2ee7aab
Added PageTitle feature
csharpfritz ffc9189
Removed unnecessary PageTitle on Index
csharpfritz b2d5164
Added PageTitle reference
csharpfritz 451cb30
Added PageTitle to 05 docs
csharpfritz ac69e9a
Removed pizza.db
csharpfritz 06ba5ef
Added segment about JSON codegen
csharpfritz dd8749c
Removed tabs in code sample
csharpfritz 23edcf9
Merge branch 'fritz-upgradenet6' of github.com:dotnet-presentations/b…
csharpfritz 245ddcc
Fixed whiespace issues
csharpfritz 6a9598b
Formatted all code with .NET format and new editorconfig
csharpfritz File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,9 @@ | ||
<Project> | ||
<PropertyGroup> | ||
<AspNetCoreVersion>5.0.0</AspNetCoreVersion> | ||
<BlazorVersion>5.0.0</BlazorVersion> | ||
<EntityFrameworkVersion>5.0.0</EntityFrameworkVersion> | ||
<SystemNetHttpJsonVersion>5.0.0</SystemNetHttpJsonVersion> | ||
<AspNetCoreVersion>6.0.0</AspNetCoreVersion> | ||
<BlazorVersion>6.0.0</BlazorVersion> | ||
<EntityFrameworkVersion>6.0.0</EntityFrameworkVersion> | ||
<TargetFrameworkVersion>net6.0</TargetFrameworkVersion> | ||
<SystemNetHttpJsonVersion>6.0.0</SystemNetHttpJsonVersion> | ||
</PropertyGroup> | ||
</Project> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<configuration> | ||
<packageSources> | ||
<!--To inherit the global NuGet package sources remove the <clear/> line below --> | ||
<clear /> | ||
<add key="nuget" value="https://api.nuget.org/v3/index.json" /> | ||
</packageSources> | ||
</configuration> | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<configuration> | ||
<packageSources> | ||
<!--To inherit the global NuGet package sources remove the <clear/> line below --> | ||
<clear /> | ||
<add key="nuget" value="https://api.nuget.org/v3/index.json" /> | ||
</packageSources> | ||
</configuration> |
3 changes: 2 additions & 1 deletion
3
save-points/00-get-started/BlazingPizza.Client/BlazingPizza.Client.csproj
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,11 @@ | ||
using Microsoft.AspNetCore.Components.WebAssembly.Hosting; | ||
using Microsoft.Extensions.DependencyInjection; | ||
using System; | ||
using System.Net.Http; | ||
using System.Threading.Tasks; | ||
using BlazingPizza.Client; | ||
using Microsoft.AspNetCore.Components.Web; | ||
using Microsoft.AspNetCore.Components.WebAssembly.Hosting; | ||
|
||
namespace BlazingPizza.Client | ||
{ | ||
public class Program | ||
{ | ||
public static async Task Main(string[] args) | ||
{ | ||
var builder = WebAssemblyHostBuilder.CreateDefault(args); | ||
builder.RootComponents.Add<App>("#app"); | ||
var builder = WebAssemblyHostBuilder.CreateDefault(args); | ||
builder.RootComponents.Add<App>("#app"); | ||
builder.RootComponents.Add<HeadOutlet>("head::after"); | ||
|
||
builder.Services.AddScoped(sp => new HttpClient { BaseAddress = new Uri(builder.HostEnvironment.BaseAddress) }); | ||
builder.Services.AddScoped(sp => new HttpClient { BaseAddress = new Uri(builder.HostEnvironment.BaseAddress) }); | ||
|
||
await builder.Build().RunAsync(); | ||
} | ||
} | ||
} | ||
await builder.Build().RunAsync(); |
3 changes: 2 additions & 1 deletion
3
...oints/00-get-started/BlazingPizza.ComponentsLibrary/BlazingPizza.ComponentsLibrary.csproj
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 9 additions & 11 deletions
20
save-points/00-get-started/BlazingPizza.ComponentsLibrary/LocalStorage.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,15 @@ | ||
using Microsoft.JSInterop; | ||
using System.Threading.Tasks; | ||
|
||
namespace BlazingPizza.ComponentsLibrary | ||
namespace BlazingPizza.ComponentsLibrary; | ||
|
||
public static class LocalStorage | ||
{ | ||
public static class LocalStorage | ||
{ | ||
public static ValueTask<T> GetAsync<T>(IJSRuntime jsRuntime, string key) | ||
=> jsRuntime.InvokeAsync<T>("blazorLocalStorage.get", key); | ||
public static ValueTask<T> GetAsync<T>(IJSRuntime jsRuntime, string key) | ||
=> jsRuntime.InvokeAsync<T>("blazorLocalStorage.get", key); | ||
|
||
public static ValueTask SetAsync(IJSRuntime jsRuntime, string key, object value) | ||
=> jsRuntime.InvokeVoidAsync("blazorLocalStorage.set", key, value); | ||
public static ValueTask SetAsync(IJSRuntime jsRuntime, string key, object value) | ||
=> jsRuntime.InvokeVoidAsync("blazorLocalStorage.set", key, value); | ||
csharpfritz marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
public static ValueTask DeleteAsync(IJSRuntime jsRuntime, string key) | ||
=> jsRuntime.InvokeVoidAsync("blazorLocalStorage.delete", key); | ||
} | ||
public static ValueTask DeleteAsync(IJSRuntime jsRuntime, string key) | ||
=> jsRuntime.InvokeVoidAsync("blazorLocalStorage.delete", key); | ||
csharpfritz marked this conversation as resolved.
Show resolved
Hide resolved
|
||
} |
17 changes: 8 additions & 9 deletions
17
save-points/00-get-started/BlazingPizza.ComponentsLibrary/Map/Marker.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,12 @@ | ||
namespace BlazingPizza.ComponentsLibrary.Map | ||
namespace BlazingPizza.ComponentsLibrary.Map; | ||
|
||
public class Marker | ||
{ | ||
public class Marker | ||
{ | ||
public string Description { get; set; } | ||
public string Description { get; set; } | ||
|
||
public double X { get; set; } | ||
public double X { get; set; } | ||
|
||
public double Y { get; set; } | ||
public double Y { get; set; } | ||
|
||
public bool ShowPopup { get; set; } | ||
} | ||
} | ||
public bool ShowPopup { get; set; } | ||
} |
13 changes: 6 additions & 7 deletions
13
save-points/00-get-started/BlazingPizza.ComponentsLibrary/Map/Point.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,8 @@ | ||
namespace BlazingPizza.ComponentsLibrary.Map | ||
namespace BlazingPizza.ComponentsLibrary.Map; | ||
|
||
public class Point | ||
{ | ||
public class Point | ||
{ | ||
public double X { get; set; } | ||
public double X { get; set; } | ||
|
||
public double Y { get; set; } | ||
} | ||
} | ||
public double Y { get; set; } | ||
} |
3 changes: 2 additions & 1 deletion
3
save-points/00-get-started/BlazingPizza.Server/BlazingPizza.Server.csproj
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 0 additions & 43 deletions
43
save-points/00-get-started/BlazingPizza.Server/NotificationsController.cs
This file was deleted.
Oops, something went wrong.
35 changes: 15 additions & 20 deletions
35
save-points/00-get-started/BlazingPizza.Server/OidcConfigurationController.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,21 @@ | ||
using Microsoft.AspNetCore.ApiAuthorization.IdentityServer; | ||
using Microsoft.AspNetCore.Mvc; | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Threading.Tasks; | ||
|
||
namespace BlazingPizza.Server | ||
namespace BlazingPizza.Server; | ||
|
||
public class OidcConfigurationController : Controller | ||
{ | ||
public class OidcConfigurationController : Controller | ||
{ | ||
public OidcConfigurationController(IClientRequestParametersProvider clientRequestParametersProvider) | ||
{ | ||
ClientRequestParametersProvider = clientRequestParametersProvider; | ||
} | ||
public OidcConfigurationController(IClientRequestParametersProvider clientRequestParametersProvider) | ||
{ | ||
ClientRequestParametersProvider = clientRequestParametersProvider; | ||
} | ||
|
||
public IClientRequestParametersProvider ClientRequestParametersProvider { get; } | ||
public IClientRequestParametersProvider ClientRequestParametersProvider { get; } | ||
|
||
[HttpGet("_configuration/{clientId}")] | ||
public IActionResult GetClientRequestParameters([FromRoute]string clientId) | ||
{ | ||
var parameters = ClientRequestParametersProvider.GetClientParameters(HttpContext, clientId); | ||
return Ok(parameters); | ||
} | ||
} | ||
} | ||
[HttpGet("_configuration/{clientId}")] | ||
public IActionResult GetClientRequestParameters([FromRoute] string clientId) | ||
{ | ||
var parameters = ClientRequestParametersProvider.GetClientParameters(HttpContext, clientId); | ||
return Ok(parameters); | ||
} | ||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.