Vex (Vex v0.9.2) View Source

Data Validation for Elixir.

Link to this section Summary

Link to this section Functions

Link to this function

validate(data, settings)

View Source

Lookup a validator from configured sources

Examples

iex> Vex.validator(:presence) Vex.Validators.Presence iex> Vex.validator(:exclusion) Vex.Validators.Exclusion

Link to this function

validator(name, sources)

View Source

Lookup a validator from given sources

Examples

iex> Vex.validator(:presence, [[presence: :presence_stub]]) :presence_stub iex> Vex.validator(:exclusion, [Vex.Validators]) Vex.Validators.Exclusion iex> Vex.validator(:presence, [Vex.Validators, [presence: :presence_stub]]) Vex.Validators.Presence iex> Vex.validator(:presence, [[presence: :presence_stub], Vex.Validators]) :presence_stub