onBackgroundMessage property

Stream<Payload> onBackgroundMessage

FCM directs push messages to your web page's onMessage callback if the user currently has it open.

Otherwise, it calls your callback passed into onBackgroundMessage.

Implementation

Stream<Payload> get onBackgroundMessage => _onBackgroundMessage.stream;