onWillChange method

void onWillChange(
  1. BuildContext context,
  2. V? previousViewModel,
  3. V newViewModel
)

A function that will be run on State change, before the Widget is built.

This can be useful for imperative calls to things like Navigator, TabController, etc

Implementation

void onWillChange(
  BuildContext context,
  V? previousViewModel,
  V newViewModel,
) {}