on method

StateBuilder on(
  1. Widget build(
    1. T
    )
)

Associates this state with a reactive widget built using the given function.

Implementation

StateBuilder on(Widget Function(T) build) {
  return StateBuilder(
    uniqueKey: uniqueKey,
    build: (dynamic value) => build(value as T),
  );
}