formulator v0.4.0 Formulator.HtmlError View Source
Link to this section Summary
Functions
Returns a struct with the appropriate error class and html for a form error.
Link to this section Functions
Link to this function
html_error(form, field)
View Source
html_error(form, field)
View Source
html_error(Phoenix.HTML.Form.t(), atom()) :: %Formulator.HtmlError{
class: term(),
html: term()
}
html_error(Phoenix.HTML.Form.t(), atom()) :: %Formulator.HtmlError{ class: term(), html: term() }
Returns a struct with the appropriate error class and html for a form error.
If there are errors on the given field,
it will have a class to use in the form field in the :class
field
and an appropriate html tag to display the error message
in the :html
field.