state property
Returns the current state.
This getter provides read-only access to the current state, and is safe to read from outside the notifier:
final count = context.read<CounterNotifier>().state;
To modify the state, use Notifier.setState.
Implementation
S get state => _state;