debugState property

  1. @Deprecated('Use state instead')
T debugState

A development-only way to access state outside of StateNotifier.

The only difference with state is that debugState is not "protected".
Will not work in release mode.

This is useful for tests.


@Deprecated('Use state instead')
T get debugState {
  late T result;
  assert(() {
    result = _state;
    return true;
  }(), '');
  return result;