defmodule Formex.Field do alias __MODULE__ @doc """ Defines the Formex.Field struct. * `:name` - a field name, for example: `:title` * `:struct_name` - a name of a key in your struct. By default the same as `:name` * `:type` - a type of a field that in most cases will be the name of a function from [`Phoenix.HTML.Form`](https://hexdocs.pm/phoenix_html/Phoenix.HTML.Form.html) * `:value` - the value from struct/params * `:required` - is field required? Used only in template, not validated * `:validation` - validation rules to be passed to a validator * `:label` - the text label * `:data` - additional data used by particular field type (eg. `:select` stores here data for `