getAttributeType method

FormifyType getAttributeType(
  1. String attribute
)

Get the type of a form attribute.

The getAttributeType function is used to retrieve the type of a form attribute based on its identifier. It looks up the attribute in the internal _attributes map and returns its type. If the attribute is not found, it defaults to FormifyType.text.

Parameters:

  • attribute: The identifier of the form attribute for which you want to retrieve the type.

Returns: The type of the specified form attribute as a FormifyType, or FormifyType.text if the attribute is not found.

Implementation

FormifyType getAttributeType(String attribute) {
  return _attributes[attribute] ?? FormifyType.text;
}