import 'package:riverpod/src/stream_provider.dart'; import '../tools/tools.dart'; enum ConnectionState { detached, detaching, attaching, attachedWeak, attachedGood, attachedStrong, fullyAttached, overAttached, } ExternalStreamState globalConnectionState = ExternalStreamState(ConnectionState.detached); AutoDisposeStreamProvider globalConnectionStateProvider = globalConnectionState.provider();