Skip to content

UseReducer

method
cref: M:Microsoft.UI.Reactor.Core.RenderContext.UseReducer``1(``0,System.Boolean)

Learn more: Hooks, Effects

Summary

Declares a piece of state with a functional updater variant. The updater receives the previous value and returns the next. Cross-thread updater calls are auto-marshaled onto the captured UI dispatcher (same semantics as UseState (guide)); pass : true for locked in-place updates that serialize many concurrent writers without an intervening UI tick.