title: firebase_messaging how to clear notification?
body: <p>I'm using <a href="https://pub.dev/packages/firebase_messaging" rel="noreferrer">firebase_messaging</a> 
  When notification comes, I'm displaying alert dialog. Below are my code.</p>
  
  <pre><code>showNotification(BuildContext context) {
      _firebaseMessaging.configure(
        onMessage: (Map&lt;String, dynamic&gt; message) async {
          print('on message $message');
          _showPushNotificationDialog(message['notification']['title'],
              message['notification']['body'], context);
        },
        onResume: (Map&lt;String, dynamic&gt; message) async {
          print('on resume $message');
          _showPushNotificationDialog(
              message['data']['title'], message['data']['body'], context);
        },
        onLaunch: (Map&lt;String, dynamic&gt; message) async {
          print('on launch $message');
          _showPushNotificationDialog(
              message['data']['title'], message['data']['body'], context);
        },
      );
    }
  </code></pre>
  
  <p>Where <code>_showPushNotificationDialog</code> method will call each times when <strong>onMessage</strong>, <strong>onResume</strong>, and <strong>onLaunch</strong> method call.</p>
  
  <p>Facing issue like when my app is in background or terminate mode and notification will come and will tap on notification tray all works good.  But when I go on other page and come back to previous one all time <code>_firebaseMessaging.configure(....</code> method call and its has data so each time my alert dialog pups up.</p>
  
  <p>So how can I clear notification that was clicked by notification tray?</p>