shouldRebuildWidget method Null safety

bool shouldRebuildWidget(
  1. SnapState oldSnap,
  2. SnapState currentSnap
)

Condition on when to rebuild the widget, it exposes the old and the new SnapState of the the state that emits the notification.

Implementation

bool shouldRebuildWidget(
    SnapState<dynamic> oldSnap, SnapState<dynamic> currentSnap) {
  return true;
}