state property Null safety

dynamic state
read / write

State associated with the validator being run.

Use this property in a custom validator to access compiled state. Compiled state is a value that has been computed from the arguments to the validator. For example, a 'greater than 1' validator, the state is an expression object that evaluates a value is greater than 1.

Set this property by returning the desired value from


dynamic state;