state property

  1. @override
T get state
override

The current state

Implementation

@override
T get state {
  return snapState.state;
}
  1. @override
set state (T value)
override

Sync state mutation.

Use setState for more options

See: stateAsync for async state mutation

Implementation

@override
set state(T value) {
  if (!isInitialized) {
    removeFromReactiveModel = addToActiveReactiveModels(this);
    isInitialized = true;
  }
  setStateNullable(
    (_) => value,
    middleSetState: middleSetState,
    stackTrace: kDebugMode ? StackTrace.current : null,
  );
}