Renamed to szg251/elm-validator-pipeline. That is where the repository lives now. It has not been published as a package under the new name.
Versions published as gege251/elm-validator-pipeline still install under that name. 5 versions of 5 come from the new location (see their notes).
Rerouted (renamed, verified). The GitHub user or repository was renamed. The tag is still there, at the new name. The Lamdera package server serves a copy recovered from https://github.com/szg251/elm-validator-pipeline.
What we checked: The repo moved to github.com/szg251/elm-validator-pipeline. Rebuilt with git archive from commit da976241819c of https://github.com/szg251/elm-validator-pipeline (zip prefix gege251-elm-validator-pipeline-da97624/, America/Los_Angeles times): the zip is byte-identical to the one package.elm-lang.org recorded, SHA-1 59bb28d471fefd60491c92fca692bcc2ba046942.
The Lamdera compiler uses this copy and prints a one-line notice saying so. elm itself fails to download this version.
Details · package.elm-lang.org's zip: https://github.com/gege251/elm-validator-pipeline/zipball/1.1.1/
Named validators work exactly the same way, as the simple ones, but every validate function takes a name string.
Ok ValidatedForm
|> validate "name" (notEmpty "name is required") form.name
|> validate "email" (isEmail "email is invalid") form.email
|> validateMany "password"
[ hasLetter "password needs to have letters"
, hasNumber "password needs to have numbers"
]
form.password
|> noCheck form.message
|> checkOnly "approved" Bool.isTrue form.approvedErrors will be accumulated from top to bottom into a Dict, where the key is the field name.
Validate a value using a validator.
Validate a value without applying it to the pipe.
Validate a value using a list of validators. Checks are performed from left to right, and will stop on the first failure, returning only the first error.
Validate a value using a list of validators. Checks are performed from left to right, and will return all errors.
Named validators return lists of errors in a Dict, where the key is the field name. You don't even
need to use these helpers to get errors for a field, you can simply use Dict.get FIELDNAME.
Validated is an alias for a Result type with Errors.
Named validators return lists of errors in a Dict, where the key is the field name.
Checks if there are any errors for a given field name.
Get errors for a given field.
Count all the errors.
Pipe a value through without perfoming any checks.