File tree Expand file tree Collapse file tree
9.0/BlazorWebAssemblyStandaloneWithIdentity Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1111 <PackageReference Include =" Microsoft.AspNetCore.Identity.EntityFrameworkCore" Version =" 9.0.0" />
1212 <PackageReference Include =" Microsoft.AspNetCore.OpenApi" Version =" 9.0.7" />
1313 <PackageReference Include =" Microsoft.EntityFrameworkCore.InMemory" Version =" 9.0.0" />
14+ <PackageReference Include =" NSwag.AspNetCore" Version =" 14.6.1" />
1415 </ItemGroup >
1516
1617</Project >
Original file line number Diff line number Diff line change 5656// Add Endpoints API Explorer
5757builder . Services . AddEndpointsApiExplorer ( ) ;
5858
59- // add OpenAPI services
60- builder . Services . AddOpenApi ( ) ;
59+ // Add NSwag services
60+ builder . Services . AddOpenApiDocument ( ) ;
6161
6262var app = builder . Build ( ) ;
6363
6767 await using var scope = app . Services . CreateAsyncScope ( ) ;
6868 await SeedData . InitializeAsync ( scope . ServiceProvider ) ;
6969
70- // resolve OpenAPI document
71- app . MapOpenApi ( ) ;
70+ // Add OpenAPI/Swagger generator and the Swagger UI
71+ app . UseOpenApi ( ) ;
72+ app . UseSwaggerUi ( ) ;
7273}
7374
7475// create routes for the identity endpoints
Original file line number Diff line number Diff line change 11[
22 {
3- "Name": "New Profile ",
3+ "Name": "Start Projects ",
44 "Projects": [
55 {
6- "Name ": "BlazorWasmAuth\\BlazorWasmAuth.csproj",
6+ "Path ": "BlazorWasmAuth\\BlazorWasmAuth.csproj",
77 "Action": "Start"
88 },
99 {
10- "Name ": "Backend\\Backend.csproj",
10+ "Path ": "Backend\\Backend.csproj",
1111 "Action": "StartWithoutDebugging"
1212 }
1313 ]
You can’t perform that action at this time.
0 commit comments