Optional function that makes the watcher rebuild only when it returns true
final bool Function()? when;