Skip to content
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

Blazor Support (Preview) #201

Merged
merged 11 commits into from
Sep 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# MacOs
.DS_Store

# Rider
.idea

Expand Down
17 changes: 0 additions & 17 deletions .run/API.run.xml

This file was deleted.

2 changes: 1 addition & 1 deletion .run/Infrastucture.run.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<component name="ProjectRunConfigurationManager">
<configuration default="false" name="Infrastucture" type="CompoundRunConfigurationType">
<toRun name="Api" type="LaunchSettings" />
<toRun name="IdentityServer" type="LaunchSettings" />
<toRun name="API" type="LaunchSettings" />
<method v="2" />
</configuration>
</component>
17 changes: 0 additions & 17 deletions .run/JS (.NET 3.1).run.xml

This file was deleted.

17 changes: 0 additions & 17 deletions .run/JS (EF).run.xml

This file was deleted.

17 changes: 0 additions & 17 deletions .run/SPA (.NET 5).run.xml

This file was deleted.

57 changes: 39 additions & 18 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
"console": "externalTerminal",
"console": "integratedTerminal",
"presentation": {
"group": "Infrastructure",
"hidden": false,
Expand All @@ -44,13 +44,13 @@
"type": "coreclr",
"request": "launch",
"preLaunchTask": "build-api",
"program": "${workspaceFolder}/samples/Api/bin/Debug/net8.0/Api.dll",
"program": "${workspaceFolder}/samples/Apis/Api/bin/Debug/net8.0/Api.dll",
"args": [],
"cwd": "${workspaceFolder}/samples/Api",
"cwd": "${workspaceFolder}/samples/Apis/Api",
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
"console": "externalTerminal",
"console": "integratedTerminal",
"presentation": {
"group": "Infrastructure",
"hidden": false,
Expand All @@ -62,13 +62,13 @@
"type": "coreclr",
"request": "launch",
"preLaunchTask": "build-api.dpop",
"program": "${workspaceFolder}/samples/Api.DPoP/bin/Debug/net8.0/Api.DPoP.dll",
"program": "${workspaceFolder}/samples/Apis/Api.DPoP/bin/Debug/net8.0/Api.DPoP.dll",
"args": [],
"cwd": "${workspaceFolder}/samples/Api.DPoP",
"cwd": "${workspaceFolder}/samples/Apis/Api.DPoP",
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
"console": "externalTerminal",
"console": "integratedTerminal",
"presentation": {
"group": "Infrastructure",
"hidden": false,
Expand All @@ -80,13 +80,13 @@
"type": "coreclr",
"request": "launch",
"preLaunchTask": "build-api.isolated",
"program": "${workspaceFolder}/samples/Api.Isolated/bin/Debug/net8.0/Api.Isolated.dll",
"program": "${workspaceFolder}/samples/Apis/Api.Isolated/bin/Debug/net8.0/Api.Isolated.dll",
"args": [],
"cwd": "${workspaceFolder}/samples/Api.Isolated",
"cwd": "${workspaceFolder}/samples/Apis/Api.Isolated",
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
"console": "externalTerminal",
"console": "integratedTerminal",
"presentation": {
"group": "Infrastructure",
"hidden": false,
Expand All @@ -108,7 +108,7 @@
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
},
"console": "externalTerminal",
"console": "integratedTerminal",
"presentation": {
"hidden": false,
"order": 10
Expand All @@ -129,7 +129,7 @@
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
},
"console": "externalTerminal",
"console": "integratedTerminal",
"presentation": {
"hidden": false,
"order": 10
Expand All @@ -150,28 +150,49 @@
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
},
"console": "externalTerminal",
"console": "integratedTerminal",
"presentation": {
"hidden": false,
"order": 10
}
},
{
"name": "Blazor Wasm",
"name": "Blazor PerComponent",
"type": "coreclr",
"request": "launch",
"preLaunchTask": "build-blazor.wasm",
"program": "${workspaceFolder}/samples/Blazor.Wasm/Blazor.Wasm.Bff/bin/Debug/net8.0/Blazor.Wasm.Bff.dll",
"preLaunchTask": "build-PerComponent",
"program": "${workspaceFolder}/samples/Blazor/PerComponent/PerComponent/bin/Debug/net8.0/PerComponent.dll",
"args": [],
"cwd": "${workspaceFolder}/samples/Blazor.Wasm/Blazor.Wasm.Bff",
"cwd": "${workspaceFolder}/samples/Blazor/PerComponent/PerComponent",
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
"serverReadyAction": {
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
},
"console": "externalTerminal",
"console": "integratedTerminal",
"presentation": {
"hidden": false,
"order": 10
}
},
{
"name": "Blazor WebAssembly",
"type": "coreclr",
"request": "launch",
"preLaunchTask": "build-WebAssembly",
"program": "${workspaceFolder}/samples/Blazor/WebAssembly/WebAssembly/bin/Debug/net8.0/WebAssembly.dll",
"args": [],
"cwd": "${workspaceFolder}/samples/Blazor/WebAssembly/WebAssembly",
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
"serverReadyAction": {
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
},
"console": "integratedTerminal",
"presentation": {
"hidden": false,
"order": 10
Expand Down
23 changes: 18 additions & 5 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"command": "dotnet",
"args": [
"build",
"${workspaceFolder}/samples/Api/Api.csproj",
"${workspaceFolder}/samples/Apis/Api/Api.csproj",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
Expand All @@ -43,7 +43,7 @@
"command": "dotnet",
"args": [
"build",
"${workspaceFolder}/samples/Api.DPoP/Api.DPoP.csproj",
"${workspaceFolder}/samples/Apis/Api.DPoP/Api.DPoP.csproj",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
Expand All @@ -55,7 +55,7 @@
"command": "dotnet",
"args": [
"build",
"${workspaceFolder}/samples/Api.Isolated/Api.Isolated.csproj",
"${workspaceFolder}/samples/Apis/Api.Isolated/Api.Isolated.csproj",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
Expand Down Expand Up @@ -110,12 +110,25 @@
"problemMatcher": "$msCompile"
},
{
"label": "build-blazor.wasm",
"label": "build-PerComponent",
"type": "process",
"command": "dotnet",
"args": [
"build",
"${workspaceFolder}/samples/Blazor.Wasm/Blazor.Wasm.Bff/Blazor.Wasm.Bff.csproj",
"${workspaceFolder}/samples/Blazor/PerComponent/PerComponent/PerComponent.csproj",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
"problemMatcher": "$msCompile"
},

{
"label": "build-WebAssembly",
"type": "process",
"command": "dotnet",
"args": [
"build",
"${workspaceFolder}/samples/Blazor/WebAssembly/WebAssembly/WebAssembly.csproj",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
Expand Down
20 changes: 16 additions & 4 deletions Directory.Build.targets
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<Project>
<PropertyGroup Condition=" '$(TargetFramework)' == 'net8.0'">
<FrameworkVersionRuntime>8.0.0</FrameworkVersionRuntime>
<FrameworkVersionTesting>8.0.0</FrameworkVersionTesting>
<FrameworkVersionTesting>8.0.8</FrameworkVersionTesting>
<WilsonVersion>7.1.2</WilsonVersion> <!-- Used in samples -->
<YarpVersion>2.1.0</YarpVersion>
<IdentityServerVersion>7.0.4</IdentityServerVersion>
<IdentityServerVersion>7.0.6</IdentityServerVersion>
</PropertyGroup>

<ItemGroup>
Expand All @@ -13,15 +14,26 @@

<!-- runtime -->
<PackageReference Update="IdentityModel" Version="7.0.0" />
<PackageReference Update="Duende.AccessTokenManagement.OpenIdConnect" Version="3.0.0-preview.3" />
<PackageReference Update="Duende.AccessTokenManagement.OpenIdConnect" Version="3.0.0" />
<PackageReference Update="Microsoft.EntityFrameworkCore.Relational" Version="$(FrameworkVersionRuntime)" />
<PackageReference Update="Microsoft.Extensions.Http" Version="$(FrameworkVersionRuntime)" />
<PackageReference Update="Microsoft.AspNetCore.Components.WebAssembly" Version="$(FrameworkVersionRuntime)" />
<PackageReference Update="Microsoft.AspNetCore.Components.WebAssembly.Server" Version="$(FrameworkVersionRuntime)" />
<PackageReference Update="Microsoft.AspNetCore.Components.WebAssembly.Authentication" Version="$(FrameworkVersionRuntime)" />
<PackageReference Update="Microsoft.AspNetCore.Components.Authorization" Version="$(FrameworkVersionRuntime)" />
<PackageReference Update="Yarp.ReverseProxy" Version="$(YarpVersion)" />

<!-- samples -->
<PackageReference Update="Serilog.AspNetCore" Version="8.0.2" />
<PackageReference Update="Microsoft.IdentityModel.JsonWebTokens" Version="$(WilsonVersion)" />
<PackageReference Update="System.IdentityModel.Tokens.Jwt" Version="$(WilsonVersion)" />

<!-- testing -->
<PackageReference Update="Microsoft.EntityFrameworkCore.InMemory" Version="$(FrameworkVersionTesting)" />
<PackageReference Update="Microsoft.AspNetCore.Authentication.JwtBearer" Version="$(FrameworkVersionTesting)" />
<PackageReference Update="Microsoft.AspNetCore.TestHost" Version="$(FrameworkVersionTesting)" />
<PackageReference Update="Microsoft.Extensions.TimeProvider.Testing" Version="$(FrameworkVersionTesting)" />
<!-- Test timeprovider is released separately from the framework, so we can't use FrameworkVersionTesting -->
<PackageReference Update="Microsoft.Extensions.TimeProvider.Testing" Version="8.8.0" />

<PackageReference Update="Duende.IdentityServer" Version="$(IdentityServerVersion)" />

Expand Down
Loading
Loading