title: Make push notifications appear as pop up when app is on background with firebase
body: <p>I am setting up push notifications with my react native app to android users using Firebase Cloud Messaging. So far I have followed <em>mostly</em> this <a href="https://medium.com/@anum.amin/react-native-integrating-push-notifications-using-fcm-349fff071591" rel="nofollow noreferrer">tutorial</a>. I managed to make push notifications to show on lock screen, and deal with them when the app is on foreground. When app is on background, though, I can't manage to show notification as a pop up. It appear on the notification tray, but it does not show a pop up, like gmail's or whatsapp's  notifications do. </p>
  
  <p>I believe my problem is that I am not sending the correct params with the message. I am using firebase console, so it's not very flexible. How can I config (programmatically) an notification to show as pop up upon receival?</p>
  
  <p>EDIT: </p>
  
  <p>Setting Up notification Channel works for newer android devices - tested on Android 8.1 (API level 27). </p>
  
  <p>On older devices - testing on Android 6.0 (API level 23) -, heads up notifications still doesn't appear. I am sending the following message using aws sns console:</p>
  
  <pre class="lang-js prettyprint-override"><code>{ 
    priority: 'high',
    content_available: true,
    notification: { 
       title: 'hello',
       body: 'Just test',
       android_channel_id: 'test-channel',
       sound: 'default' 
    },
    data: { title: 'title', body: 'body', sound: 'default' }
  }
  
  </code></pre>
  
  <p>I also sent messages using Firebase console setting Priority High and Sound Enabled, with and without Android Channel Id. None of that worked. The notification arrives silently on tray bar. This <a href="https://github.com/invertase/react-native-firebase/issues/1297" rel="nofollow noreferrer">discussion</a> shows the same problems, but the <a href="https://medium.com/@yangnana11/how-to-set-up-firebase-notification-in-react-native-app-android-only-4920eb875eae" rel="nofollow noreferrer">solution</a> one person pointed did not work for me. I didn't go through editing the react-native library code a lot. I tried section <strong>Problems with older Android version (Foreground)</strong>, it made heads up appear on foreground, but not on background, which is the intended behaviour here.</p>
  
  <p>Furthermore, is seems that this is an unresolved issue to quite a few people using this react native package (<a href="https://github.com/invertase/react-native-firebase/issues/2059" rel="nofollow noreferrer">github issue</a>, <a href="https://github.com/invertase/react-native-firebase/issues/1781" rel="nofollow noreferrer">github issue</a>). </p>
  
  <p>So, I think I should reformulate my question. For Android 7.1 or lower(testing on 6.0): </p>
  
  <ol>
  <li><p>Is setting priority='high' and notification.sound='default' supposed to be enough to show heads up notification? (From my research it should be)</p></li>
  <li><p>Do I need to make any further configuration on my application code to go from notification arriving silently on tray bar to it appering as a heads up?</p></li>
  </ol>