validatex v0.3.0 Validatex.Validation View Source
This module helps with validation of input forms.
Link to this section Summary
Link to this section Types
Link to this type
event(raw)
View Sourceevent(raw) :: on_submit() | on_blur() | on_related_change() | on_change(raw)
Link to this type
validator(a, b)
View Sourcevalidator(a, b) :: (a -> Result.t(error_or_errors(), b))
Link to this section Functions
Link to this function
extract_error(arg)
View Sourceextract_error(field(any(), any())) :: ExMaybe.t(error_or_errors())
Link to this function
field(raw)
View Sourcefield(raw) :: {:field, raw, :not_validated} when raw: var
Link to this function
invalidate(arg, err)
View Sourceinvalidate(field(raw, any()), String.t()) :: {:field, raw, {:invalid, error_or_errors()}} when raw: var
Link to this function
optional_field(raw)
View Sourceoptional_field(raw) :: {:field, raw, :not_validated} when raw: var