You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: aspnetcore/data/scaffold_RP.md
+17-16Lines changed: 17 additions & 16 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -33,9 +33,9 @@ To launch the interactive tool, run `dotnet scaffold`. The UI changes as more fe
33
33
34
34
To navigate the UI, use the:
35
35
36
-
- Up and down arrow keys to navigate the menu items.
37
-
- Enter key to select the highlighted menu item.
38
-
- Select and enter **Back** to return to the previous menu.
36
+
* Up and down arrow keys to navigate the menu items.
37
+
* Enter key to select the highlighted menu item.
38
+
* Select and enter **Back** to return to the previous menu.
39
39
40
40
## Create and scaffold a data model in a Razor Pages project
41
41
@@ -59,11 +59,11 @@ If you have any problems with the following steps, see [Tutorial: Create a Razor
59
59
60
60
The `dotnet scaffold` tool makes the following changes to the project files:
61
61
62
-
- A package reference is added for Entity Framework.
63
-
- `Program.cs` is updated to initialize the database connection.
64
-
- `appsettings.json` is updated with connection information.
65
-
- `ContactDbContext.cs` is created and added to the project root directory.
66
-
- Razor Pages for CRUD operations are added to the Pages folder.
62
+
* A package reference is added for Entity Framework.
63
+
* `Program.cs` is updated to initialize the database connection.
64
+
* `appsettings.json` is updated with connection information.
65
+
* `ContactDbContext.cs` is created and added to the project root directory.
66
+
* Razor Pages for CRUD operations are added to the Pages folder.
67
67
68
68
The content has been generated but the database isn't initialized. Run the following commands to initialize the DB.
69
69
@@ -75,10 +75,11 @@ dotnet ef database update
75
75
```
76
76
77
77
In The preceding commands:
78
-
-`dotnet tool uninstall --global dotnet-ef` uninstalls the `dotnet-ef` tool. Uninstalling ensures the latest tool is successfully installed. If `dotnet-ef` isn't installed, an error messages **A tool with the package Id 'dotnet-ef' could not be found.** You can ignore this message.
79
-
-`dotnet tool install --global dotnet-ef` installs globally the `dotnet-ef` tool.
80
-
-`dotnet ef migrations add initialMigration` adds the initial migration. For more information, see [Create the initial database schema using EF's migration feature](/aspnet/core/tutorials/razor-pages/model&tabs=visual-studio-code)
81
-
-`dotnet ef database update` applies the migrations to the database.
78
+
79
+
*`dotnet tool uninstall --global dotnet-ef` uninstalls the `dotnet-ef` tool. Uninstalling ensures the latest tool is successfully installed. If `dotnet-ef` isn't installed, an error messages **A tool with the package Id 'dotnet-ef' could not be found.** You can ignore this message.
80
+
*`dotnet tool install --global dotnet-ef` installs globally the `dotnet-ef` tool.
81
+
*`dotnet ef migrations add initialMigration` adds the initial migration. For more information, see [Create the initial database schema using EF's migration feature](/aspnet/core/tutorials/razor-pages/model&tabs=visual-studio-code)
82
+
*`dotnet ef database update` applies the migrations to the database.
82
83
83
84
Run the app:
84
85
@@ -91,7 +92,7 @@ Run the app:
91
92
92
93
## Additional resources
93
94
94
-
-[dotnet scaffold repo on GitHub](https://github.com/dotnet/Scaffolding)
95
-
-[How to manage .NET tools](/dotnet/core/tools/global-tools)
Copy file name to clipboardExpand all lines: aspnetcore/diagnostics/mvc1000.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -24,8 +24,8 @@ Rendering a partial using `IHtmlHelper.Partial` or `IHtmlHelper.RenderPartial` e
24
24
25
25
## How to fix violations
26
26
27
-
- Use the <xref:Microsoft.AspNetCore.Mvc.TagHelpers.PartialTagHelper>
28
-
- Use the <xref:Microsoft.AspNetCore.Mvc.Rendering.HtmlHelperPartialExtensions.PartialAsync%2A> or <xref:Microsoft.AspNetCore.Mvc.Rendering.HtmlHelperPartialExtensions.RenderPartialAsync%2A>
27
+
* Use the <xref:Microsoft.AspNetCore.Mvc.TagHelpers.PartialTagHelper>
28
+
* Use the <xref:Microsoft.AspNetCore.Mvc.Rendering.HtmlHelperPartialExtensions.PartialAsync%2A> or <xref:Microsoft.AspNetCore.Mvc.Rendering.HtmlHelperPartialExtensions.RenderPartialAsync%2A>
Copy file name to clipboardExpand all lines: aspnetcore/fundamentals/apis.md
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,12 +34,12 @@ Both API projects refer to the following class:
34
34
35
35
Minimal APIs have many of the same capabilities as controller-based APIs. They support the configuration and customization needed to scale to multiple APIs, handle complex routes, apply authorization rules, and control the content of API responses. There are a few capabilities available with controller-based APIs that are not yet supported or implemented by minimal APIs. These include:
36
36
37
-
- No built-in support for model binding (<xref:Microsoft.AspNetCore.Mvc.ModelBinding.IModelBinderProvider>, <xref:Microsoft.AspNetCore.Mvc.ModelBinding.IModelBinder>). Support can be added with a custom binding shim.
38
-
- No built-in support for validation (<xref:Microsoft.AspNetCore.Mvc.ModelBinding.Validation.IModelValidator>).
39
-
- No support for [application parts](xref:mvc/extensibility/app-parts) or the [application model](xref:mvc/controllers/application-model). There's no way to apply or build your own conventions.
40
-
- No built-in view rendering support. We recommend using [Razor Pages](xref:tutorials/razor-pages/razor-pages-start) for rendering views.
41
-
- No support for [JsonPatch](https://www.nuget.org/packages/Microsoft.AspNetCore.JsonPatch/)
42
-
- No support for [OData](https://www.nuget.org/packages/Microsoft.AspNetCore.OData/)
37
+
* No built-in support for model binding (<xref:Microsoft.AspNetCore.Mvc.ModelBinding.IModelBinderProvider>, <xref:Microsoft.AspNetCore.Mvc.ModelBinding.IModelBinder>). Support can be added with a custom binding shim.
38
+
* No built-in support for validation (<xref:Microsoft.AspNetCore.Mvc.ModelBinding.Validation.IModelValidator>).
39
+
* No support for [application parts](xref:mvc/extensibility/app-parts) or the [application model](xref:mvc/controllers/application-model). There's no way to apply or build your own conventions.
40
+
* No built-in view rendering support. We recommend using [Razor Pages](xref:tutorials/razor-pages/razor-pages-start) for rendering views.
41
+
* No support for [JsonPatch](https://www.nuget.org/packages/Microsoft.AspNetCore.JsonPatch/)
42
+
* No support for [OData](https://www.nuget.org/packages/Microsoft.AspNetCore.OData/)
Copy file name to clipboardExpand all lines: aspnetcore/fundamentals/includes/apis6.md
+7-7Lines changed: 7 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -20,13 +20,13 @@ Both API projects refer to the following class:
20
20
21
21
Minimal APIs have many of the same capabilities as controller-based APIs. They support the configuration and customization needed to scale to multiple APIs, handle complex routes, apply authorization rules, and control the content of API responses. There are a few capabilities available with controller-based APIs that are not yet supported or implemented by minimal APIs. These include:
22
22
23
-
- No built-in support for model binding (<xref:Microsoft.AspNetCore.Mvc.ModelBinding.IModelBinderProvider>, <xref:Microsoft.AspNetCore.Mvc.ModelBinding.IModelBinder>). Support can be added with a custom binding shim.
24
-
- No support for binding from forms. This includes binding <xref:Microsoft.AspNetCore.Http.IFormFile>.
25
-
- No built-in support for validation (<xref:Microsoft.AspNetCore.Mvc.ModelBinding.Validation.IModelValidator>).
26
-
- No support for [application parts](xref:mvc/extensibility/app-parts) or the [application model](xref:mvc/controllers/application-model). There's no way to apply or build your own conventions.
27
-
- No built-in view rendering support. We recommend using [Razor Pages](xref:tutorials/razor-pages/razor-pages-start) for rendering views.
28
-
- No support for [JsonPatch](https://www.nuget.org/packages/Microsoft.AspNetCore.JsonPatch/)
29
-
- No support for [OData](https://www.nuget.org/packages/Microsoft.AspNetCore.OData/)
23
+
* No built-in support for model binding (<xref:Microsoft.AspNetCore.Mvc.ModelBinding.IModelBinderProvider>, <xref:Microsoft.AspNetCore.Mvc.ModelBinding.IModelBinder>). Support can be added with a custom binding shim.
24
+
* No support for binding from forms. This includes binding <xref:Microsoft.AspNetCore.Http.IFormFile>.
25
+
* No built-in support for validation (<xref:Microsoft.AspNetCore.Mvc.ModelBinding.Validation.IModelValidator>).
26
+
* No support for [application parts](xref:mvc/extensibility/app-parts) or the [application model](xref:mvc/controllers/application-model). There's no way to apply or build your own conventions.
27
+
* No built-in view rendering support. We recommend using [Razor Pages](xref:tutorials/razor-pages/razor-pages-start) for rendering views.
28
+
* No support for [JsonPatch](https://www.nuget.org/packages/Microsoft.AspNetCore.JsonPatch/)
29
+
* No support for [OData](https://www.nuget.org/packages/Microsoft.AspNetCore.OData/)
Copy file name to clipboardExpand all lines: aspnetcore/fundamentals/minimal-apis/security.md
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -51,8 +51,8 @@ In some cases, such as controlling middleware order, it's necessary to explicitl
51
51
52
52
Authentication strategies typically support a variety of configurations that are loaded via options. Minimal apps support loading options from configuration for the following authentication strategies:
The ASP.NET Core framework expects to find these options under the `Authentication:Schemes:{SchemeName}` section in [configuration](/aspnet/core/fundamentals/configuration). In the following sample, two different schemes, `Bearer` and `LocalAuthIssuer`, are defined with their respective options. The `Authentication:DefaultScheme` option can be used to configure the default authentication strategy that's used.
58
58
@@ -102,13 +102,13 @@ Configuring authorization requirements on a resource is a two-step process that
102
102
103
103
In the following code, <xref:Microsoft.Extensions.DependencyInjection.PolicyServiceCollectionExtensions.AddAuthorizationBuilder%2A> is invoked which:
104
104
105
-
- Adds authorization-related services to the DI container.
106
-
- Returns an <xref:Microsoft.AspNetCore.Authorization.AuthorizationBuilder> that can be used to directly register authorization policies.
105
+
* Adds authorization-related services to the DI container.
106
+
* Returns an <xref:Microsoft.AspNetCore.Authorization.AuthorizationBuilder> that can be used to directly register authorization policies.
107
107
108
108
The code creates a new authorization policy, named `admin_greetings`, that encapsulates two authorization requirements:
109
109
110
-
- A role-based requirement via <xref:Microsoft.AspNetCore.Authorization.AuthorizationPolicyBuilder.RequireRole%2A> for users with an `admin` role.
111
-
- A claim-based requirement via <xref:Microsoft.AspNetCore.Authorization.AuthorizationPolicyBuilder.RequireClaim%2A> that the user must provide a `greetings_api` scope claim.
110
+
* A role-based requirement via <xref:Microsoft.AspNetCore.Authorization.AuthorizationPolicyBuilder.RequireRole%2A> for users with an `admin` role.
111
+
* A claim-based requirement via <xref:Microsoft.AspNetCore.Authorization.AuthorizationPolicyBuilder.RequireClaim%2A> that the user must provide a `greetings_api` scope claim.
112
112
113
113
The `admin_greetings` policy is provided as a required policy to the `/hello` endpoint.
Copy file name to clipboardExpand all lines: aspnetcore/fundamentals/openapi/include-metadata.md
+4-3Lines changed: 4 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -516,9 +516,10 @@ public record Todo(
516
516
In a class, struct, or record, properties with the [`[Required]`](xref:System.ComponentModel.DataAnnotations.RequiredAttribute) attribute or [required](/dotnet/csharp/language-reference/proposals/csharp-11.0/required-members#required-modifier) modifier are always `required` in the corresponding schema.
517
517
518
518
Other properties may also be required based on the constructors (implicit and explicit) for the class, struct, or record.
519
-
- For a class or record class with a single public constructor, any property with the same type and name (case-insensitive match) as a parameter to the constructor is required in the corresponding schema.
520
-
- For a class or record class with multiple public constructors, no other properties are required.
521
-
- For a struct or record struct, no other properties are required since C# always defines an implicit parameterless constructor for a struct.
519
+
520
+
* For a class or record class with a single public constructor, any property with the same type and name (case-insensitive match) as a parameter to the constructor is required in the corresponding schema.
521
+
* For a class or record class with multiple public constructors, no other properties are required.
522
+
* For a struct or record struct, no other properties are required since C# always defines an implicit parameterless constructor for a struct.
0 commit comments