ios icon indicating copy to clipboard operation
ios copied to clipboard

Need event listener when notification onShow

Open muslimmuda15 opened this issue 1 year ago • 0 comments

I need event listener when notif is fire by schedule time.

useEffect(() => {
      const type = 'notification';
      PushNotificationIOS.addEventListener(type, onRemoteNotification);
      return () => {
           PushNotificationIOS.removeEventListener(type);
      };
});

const onRemoteNotification = notification => {
      const actionIdentifier = notification.getActionIdentifier();
      console.log('NOTIF ACTION IDENTIFIER :', actionIdentifier);
}

I have no any text in my console when notif is fired.

muslimmuda15 avatar May 20 '24 01:05 muslimmuda15