- SDK Version: 38.0
- Platforms: Android 10
- react: “16.11.0”
- expo-notifications: ~0.3.3
- expo-permissions: ~9.0.1
So I was trying to delete a specific notification that the user assigns at specific time, but at the documentation, there was just how to schedule then immediately delete that notification.
I tried to make an id that has the schedulenotificationasync that has the specific data to the notification that has been made but it just makes my app glitchy and memory leak
Here are variable that user can change:
{name, jero(this means date), hour, minute} using usestate hook
Here is my code:
async function sendPushNotification(expoPushToken) {
await Notifications.scheduleNotificationAsync({
content: {
title: name,
},
trigger: jero.setHours(hour, minute, 0, 0),
});
}
I tried to assign those specific variable stored in a data to the cancelschedulenotificationbut it just does not work