watch static method

void watch(
  1. BuildContext context, {
  2. required List<Type> on,
})

Attaches context to the mutations given in on param. When a mutation specified execute widget will rebuild.

Implementation

static void watch(BuildContext context, {required List<Type> on}) {
  for (final mutant in on) {
    context.dependOnInheritedWidgetOfExactType<_VxStateModel>(
      aspect: mutant,
    );
  }
}