shouldRebuild method

  1. @override
bool shouldRebuild(
  1. covariant YSliverDelegate oldDelegate
)
override

Whether this delegate is meaningfully different from the old delegate.

If this returns false, then the header might not be rebuilt, even though the instance of the delegate changed.

This must return true if oldDelegate and this object would return different values for minExtent, maxExtent, snapConfiguration, or would return a meaningfully different widget tree from build for the same arguments.

Implementation

@override //是否需要重建
bool shouldRebuild(YSliverDelegate oldDelegate) => false;