diff --git a/Examples/simple-fcm-client/app/App.js b/Examples/simple-fcm-client/app/App.js index c1e375492a739f97e3fba683db4ad225ad87ccc4..fbcc2e808503e9f9d4b510bb0682670649ddc042 100644 --- a/Examples/simple-fcm-client/app/App.js +++ b/Examples/simple-fcm-client/app/App.js @@ -66,7 +66,7 @@ class MainPage extends Component { showLocalNotification() { FCM.presentLocalNotification({ - id: "UNIQ_ID_STRING", // (optional for instant notification) + id: new Date().valueOf().toString(), // (optional for instant notification) title: "Test Notification with action", // as FCM payload body: "Force touch to reply", // as FCM payload (required) sound: "bell.mp3", // "default" or filename diff --git a/Examples/simple-fcm-client/app/Listeners.js b/Examples/simple-fcm-client/app/Listeners.js index e76186cb224ec8a90a8960d6ac465cbbbd18a75f..942e9f269ffb9a441d90ccf2e6a9cf60adb8c62c 100644 --- a/Examples/simple-fcm-client/app/Listeners.js +++ b/Examples/simple-fcm-client/app/Listeners.js @@ -61,6 +61,9 @@ export function registerAppListener(navigation){ navigation.navigate('Detail') }, 500) } + setTimeout(()=>{ + alert(`User tapped notification\n${JSON.stringify(notif)}`) + }, 500) } if(Platform.OS ==='ios'){