Closed rynowak closed 5 years ago
Action items:
EditContextExpressionExtensions
doesn't need to be extension methodsFieldChangedEventArgs
and others should inherit from `EventArgsFieldIdentifier
should implement IEquatable<>
ValidationMessageStore.AddRange
should be Add
ValidationMessageStoreExpressionExtensions
doesn't need to be extension methodsGetValidationMessages
should have in
EditContextFieldClassExtensions
and others - all usages of "Class" should be "CssClass"InputBase
make FieldClass
privateValidationMessage
and ValidationSummary
need to use the protected virtual dispose patternMy 2 cts : I don't understand the "Edit" prefix, a validated form can be something else than an edit like a query or insert. ValidationForm and ValidationContext. This will improve discovery of api and will reduce confusion for future dev
My 2 cts : I don't understand the "Edit" prefix, a validated form can be something else than an edit like a query or insert. ValidationForm and ValidationContext. This will improve discovery of api and will reduce confusion for future dev
I think I understand where you're coming from, but these types track the editing state as well as the validation state - I think it's pretty hard to make an argument about discoverability as long as we're consistent - I expect new people to get this kind of information from docs and samples. @SteveSandersonMS - you picked the names of all of these things - care to chime in?
Yes, it's very much about editing state in general (as in, editing a form, which you could do as part of the process of "inserting" a new domain object). Validation is only one of the subscenarios this supports. So I'm happy with the naming.
Ok I see your point. One last thought "Edit" seems to be too much about write (we can create a searching form for instance), my last suggestion would be "BindedForm" and "BindingContext" but if it seems fine to you then there is no point in continuing the debate.
Summary
This is Blazor's support for forms and validation.
This consists of a base validation system that lives in
Microsoft.AspNetCore.Components
and a<form>
-based validation system that lives inMicrosoft.AspNetCore.Components.Web
.Components APIs
Web APIs