Android Notification not popping up

Please provide the following:

  1. SDK Version: 35.0.0
  2. Platforms(Android/iOS/web/all): Android, iOS

I have a problem similar to this one - Pop-up / Heads-Up Push Notifications on Android - #2 by jamesattard

I am on Android 6

In my App at the top I do this:

if (isAndroid) {
    Notifications.createChannelAndroidAsync('updates', {
        name: 'updates',
        sound: true,
        priority: 'high'
    });
}

And then when I send a notification from my server I do this:

const { Expo } = require('expo-server-sdk');
const expo = new Expo();

await expo.sendPushNotificationsAsync(expo.chunkPushNotifications([
{
        to: token,
        sound: 'default',
        title: 'test title',
        body: 'test body',
        _displayInForeground: true,
        priority: 'high',
        channelId: 'updates',
        data: { foo: true },
}
]))

The notification comes up in the tray in the background, but it doesn’t popup. So the user never sees it unless he pulls the overlay menu from the top.

Any ideas on how to get the notification to actually pop?

Hey @noitidart,

We’re currently working on a complete re-write of our Notifications module that aims to address these cases. Unfortunately that means in the interim, the current module won’t be getting any updates.

Cheers,
Adam

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.