radioGroupValue<T> method
Retrieves the value of a RadioGroupFieldState for a specified fieldName.
This method simplifies fetching the current value of a radio button group.
- Parameter
fieldNameThe name of the field to fetch. - Returns: The current value of the field or
nullif not set. - Throws: ArgumentError if the field doesn't exist.
Implementation
T radioGroupValue<T>(String fieldName) {
return radioGroup<T>(fieldName).value;
}