title: react native firebase messaging click notification
body: <p>I received the notification from the sender, when I click the notification, app opened.</p>
  
  <p>However, the notification return value does not call to the <code>onMessage()</code> function.</p>
  
  <p>From the <a href="https://rnfirebase.io/docs/v3.1.x/messaging/reference/messaging" rel="nofollow noreferrer">documentation</a> , function <code>getInitialNotification()</code> is do what I need. But still not get any value from <code>onMessage()</code> when app opened.</p>
  
  <pre><code>  componentDidMount(){
      firebase.messaging().getInitialNotification();
      firebase.messaging().onMessage(function(payload) {
        console.log("Message received. ", payload);
        // ...
      });
    }
  </code></pre>