File tree Expand file tree Collapse file tree
8.0/BlazorWebAssemblyStandaloneWithIdentity/BlazorWasmAuth/Identity
9.0/BlazorWebAssemblyStandaloneWithIdentity Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ using System . Net ;
12using System . Net . Http . Json ;
23using System . Security . Claims ;
4+ using System . Text ;
35using System . Text . Json ;
46using Microsoft . AspNetCore . Components . Authorization ;
57using BlazorWasmAuth . Identity . Models ;
6- using System . Text ;
78
89namespace BlazorWasmAuth . Identity
910{
Original file line number Diff line number Diff line change 99
1010 <ItemGroup >
1111 <PackageReference Include =" Microsoft.AspNetCore.Identity.EntityFrameworkCore" Version =" 9.0.0" />
12+ <PackageReference Include =" Microsoft.AspNetCore.OpenApi" Version =" 9.0.7" />
1213 <PackageReference Include =" Microsoft.EntityFrameworkCore.InMemory" Version =" 9.0.0" />
13- <PackageReference Include =" NSwag.AspNetCore" Version =" 14.1.0" />
1414 </ItemGroup >
1515
1616</Project >
Original file line number Diff line number Diff line change 5656// add services to the container
5757builder . Services . AddEndpointsApiExplorer ( ) ;
5858
59- // add NSwag services
60- builder . Services . AddOpenApiDocument ( ) ;
59+ // add OpenAPI services
60+ builder . Services . AddOpenApi ( ) ;
6161
6262var app = builder . Build ( ) ;
6363
6767 await using var scope = app . Services . CreateAsyncScope ( ) ;
6868 await SeedData . InitializeAsync ( scope . ServiceProvider ) ;
6969
70- // add OpenAPI/Swagger generator and the Swagger UI
71- app . UseOpenApi ( ) ;
72- app . UseSwaggerUi ( ) ;
70+ // resolve OpenAPI document
71+ app . MapOpenApi ( ) ;
7372}
7473
7574// create routes for the identity endpoints
Original file line number Diff line number Diff line change 1+ using System . Net ;
12using System . Net . Http . Json ;
23using System . Security . Claims ;
4+ using System . Text ;
35using System . Text . Json ;
46using Microsoft . AspNetCore . Components . Authorization ;
57using BlazorWasmAuth . Identity . Models ;
6- using System . Text ;
78
89namespace BlazorWasmAuth . Identity
910{
You can’t perform that action at this time.
0 commit comments