How to use the react-native-push-notification.clearAllNotifications function in react-native-push-notification

To help you get started, we’ve selected a few react-native-push-notification examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github DefinitelyTyped / DefinitelyTyped / types / react-native-push-notification / react-native-push-notification-tests.ts View on Github external
PushNotification.unregister();
PushNotification.localNotification = (details) => {};
PushNotification.localNotificationSchedule = (details) => {};
PushNotification.requestPermissions();
PushNotification.presentLocalNotification = (details) => {};
PushNotification.scheduleLocalNotification = (details) => {};
PushNotification.cancelLocalNotifications = (details) => {};
PushNotification.cancelAllLocalNotifications();
PushNotification.setApplicationIconBadgeNumber(1);
PushNotification.getApplicationIconBadgeNumber((badgeCount) => {});
PushNotification.popInitialNotification((notification) => {});
PushNotification.checkPermissions((checkPermissions) => {});
PushNotification.abandonPermissions();
PushNotification.registerNotificationActions(['Accept', 'Reject', 'Yes', 'No']);
PushNotification.clearAllNotifications();
github CMP-Studio / DawnChorus / app / actions / notifications.js View on Github external
export function clearNotifications(alarm) {
  if (Platform.OS === 'ios') {
    NotificationsIOS.cancelLocalNotification(alarm.uuid.toString());
  } else if (Platform.OS === 'android') {
    PushNotification.cancelLocalNotifications({ alarmUUID: alarm.uuid });
    PushNotification.clearAllNotifications();
  }
  return (Object.assign({}, alarm, { notifications: [] }));
}