Description
Per Ondřej's suggestion in #35972 (for .NET 6 or later because Minimal APIs didn't arrive until .NET 6) ...
- Idea: Replace use of MVC controller with Minimal API in the section "Server validation with a validator component" to showcase the unified validation experience
- The API controller uses MVC-based validation which also uses
DataAnnotations attribute to specify validation rules. However, it is configured differently and might have different behavior in some cases (e.g. validation is skipped with ValidateNever attribute in MVC but with SkipValidation attribute in the unified validation code)
- Up for debate: Speaking of "server validation" and "client validation" might also be a bit confusing in the context of Blazor Server - maybe rephrase the section using terminology such as "data API", "backend", or "backend API"?
Page URL
https://learn.microsoft.com/en-us/aspnet/core/blazor/forms/validation?view=aspnetcore-9.0
Content source URL
https://github.com/dotnet/AspNetCore.Docs/blob/main/aspnetcore/blazor/forms/validation.md
Document ID
bcb470e1-c859-0549-b4ef-c6c9b7ef2c72
Platform Id
b4c1bad9-fc7a-21f5-2552-f0f3617f77db
Article author
@guardrex
Metadata
- ID: bcb470e1-c859-0549-b4ef-c6c9b7ef2c72
- PlatformId: b4c1bad9-fc7a-21f5-2552-f0f3617f77db
- Service: aspnet-core
- Sub-service: blazor
Related Issues
Description
Per Ondřej's suggestion in #35972 (for .NET 6 or later because Minimal APIs didn't arrive until .NET 6) ...
DataAnnotationsattribute to specify validation rules. However, it is configured differently and might have different behavior in some cases (e.g. validation is skipped withValidateNeverattribute in MVC but withSkipValidationattribute in the unified validation code)Page URL
https://learn.microsoft.com/en-us/aspnet/core/blazor/forms/validation?view=aspnetcore-9.0
Content source URL
https://github.com/dotnet/AspNetCore.Docs/blob/main/aspnetcore/blazor/forms/validation.md
Document ID
bcb470e1-c859-0549-b4ef-c6c9b7ef2c72
Platform Id
b4c1bad9-fc7a-21f5-2552-f0f3617f77db
Article author
@guardrex
Metadata
Related Issues