orchestrator_provider 0.5.0
orchestrator_provider: ^0.5.0 copied to clipboard
Provider/ChangeNotifier integration for orchestrator_core. Build scalable Flutter apps with Event-Driven Orchestrator pattern.
orchestrator_provider #
Provider/ChangeNotifier integration for orchestrator_core. Build scalable Flutter apps with Event-Driven Orchestrator pattern.
Features #
- OrchestratorNotifier: ChangeNotifier with job dispatch and event routing
- Automatic Active/Passive event classification
- Lifecycle integration with Provider
Installation #
dependencies:
orchestrator_provider: ^0.2.0
Usage #
class CounterNotifier extends OrchestratorNotifier<CounterState> {
CounterNotifier() : super(const CounterState());
void increment() {
state = state.copyWith(isLoading: true);
dispatch(IncrementJob());
}
@override
void onActiveSuccess(JobSuccessEvent event) {
state = state.copyWith(count: event.data, isLoading: false);
}
}
Documentation #
See the full documentation.
License #
MIT License