Skip to main content

Module binding

Module binding 

Source
Expand description

Lock-backed bindings with keypath projection (SwiftUI Binding dynamic-member style).

Reads and writes go through the store’s shared mutex — no full-state clone. Project a field with StateBinding::project / ProjectedBinding::project.

When a keypath cannot focus (e.g. None in an Option field), ProjectedBinding::with and ProjectedBinding::with_mut return None instead of panicking.

Structs§

ComposedBinding
Two-segment keypath projection from root state.
ProjectedBinding
A field projected from a StateBinding through a keypath.
ReadProjectedBinding
Read-only projected field from ReadStateBinding.
ReadStateBinding
Read-only binding over RwLock state — many concurrent readers.
RwProjectedBinding
Projected field from RwStateBinding.
RwStateBinding
Read/write binding over RwLock state — writes take exclusive lock.
StateBinding
Read/write access to store state without cloning S.