react-native-push-notification
react-native-push-notification copied to clipboard
Vibration pattern not working
I am using this library along with firebase messaging, and when a notification is received, PushNotification.localNotification is fired, and the notification is displayed successfully, but I want the notification to vibrate in particular pattern , but it is not working I have also tried it with vibrate: true.
below is my code
PushNotification.localNotification({
channelId: message.data.android_channel_id,
ticker: 'My Notification Ticker',
autoCancel: true,
smallIcon: 'ic_notification',
bigText:'Description',
color: '#00add4',
vibrate: true,
vibration:[180, 121, 134, 300, 289, 123, 134, 300, 621, 121, 134, 300, 289, 123, 134, 300],
tag: 'some_tag',
group: 'group',
groupSummary: false,
ongoing: false,
actions: [YES,NO]
invokeApp: true,
when: null,
usesChronometer: false,
timeoutAfter: null,
/* iOS only properties */
category: '',
/* iOS and Android properties */
id:msgData.MsgInID,
message: message.data.message,
userInfo: { screen: 'Alarm' },
playSound: true,
soundName:message.data.soundName,
number: 10,
});
Hi @vandana87 Yes vibration pattern are not implemented. PR are welcome! Regards
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 30 days if no further activity occurs. Thank you for your contributions.