react-native-fcm: FCM.presentLocalNotification is undefined
I am trying to show notification in android app. Following event is triggering when I am receiving notification. I have used FCM.presentLocalNotification({}) inside but I am getting error undefined not a function. I console FCM object but did not found many function which is described in github
this.notificationUnsubscribe = FCM.on('notification', (notif) => {
FCM.presentLocalNotification({
id: "UNIQ_ID_STRING",
title: "My Notification Title",
body: "My Notification Message",
sound: "default",
.....
})
});
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 16 (7 by maintainers)
you may use another local notification library. why do you stick with old RN? ask the blocking repo to upgrade or fork it yourself. It is easy