NotificationListener<T extends Notification> constructor Null safety

const NotificationListener<T extends Notification>(
  1. {Key? key,
  2. required Widget child,
  3. NotificationListenerCallback<T>? onNotification}
)

Creates a widget that listens for notifications.

Implementation

const NotificationListener({
  Key? key,
  required this.child,
  this.onNotification,
}) : super(key: key);