PROTOCOL

FormField

public protocol FormField: Codable, Equatable, Sendable

The base protocol for a form field model that contains common properties. Specific implementation classes should be used to access specific information.

Properties

name

var name: String

The name of the field.

label

var label: Message?

The label describing the purpose of the field to the user.

placeholder

var placeholder: Message?

A hint for possible values of the field.

Methods

isEqualTo(_:)

func isEqualTo(_ other: any FormField) -> Bool

Returns a Bool value that indicates whether the receiver and a given object are equal.

Parameters

Name Description
other The object to compare with.