circuitry_flutter 0.1.0
circuitry_flutter: ^0.1.0 copied to clipboard
Flutter bridge for Circuitry with InheritedWidget scoping, reactive state matching, and async lifecycle management.
Changelog #
0.1.0 #
Initial release of Circuitry Flutter: the Flutter companion package for Circuitry.
Features #
- Pure Dart Core Re-export: Re-exports
package:circuitry/circuitry.dartso Flutter applications only need to depend oncircuitry_flutter. - Sealed
CircuitStateHierarchy: Pattern matchCircuitBuilding,CircuitReady, andCircuitFailureusing modern Dart 3 switch expressions. - Asynchronous Build Lifecycle (
CircuitProvider): Asynchronously compilesCircuitWirerecipes, displays loading/splash UI while resolving, and wraps child widgets in an internalInheritedWidgetscope once ready. - Monotonic Epoch Race Prevention: Safely handles dynamic wire updates (
didUpdateWidget) without race conditions, canceling and disposing superseded in-flight builds. - Automatic Unmount Cleanup: Automatically tears down and disposes the active circuit when
CircuitProvideris unmounted from the widget tree. - Synchronous Value Injection (
CircuitProvider.value): Injects pre-compiledCircuitinstances for widget test harnesses or sub-trees without managing lifecycle disposal. - Explicit Scoped Accessors: Context retrieval via
CircuitProvider.of(context)andCircuitProvider.maybeOf(context)withoutBuildContextextension pollution.