@diegomachado wrote:
After migrate to Ionic Pro, I’m trying to configure a new method to send push notification. I can register the devices and send notification with OneSignal, but I’m can’t get PlayerId or send tags.
This is my code:
this.oneSignal.startInit('xxxxxx', 'xxxxxx'); this.oneSignal.inFocusDisplaying(this.oneSignal.OSInFocusDisplayOption.InAppAlert); this.oneSignal.handleNotificationReceived().subscribe(() => { console.log('push received') }); this.oneSignal.handleNotificationOpened().subscribe(() => { console.log('push opened') }); this.oneSignal.sendTag('device_uuid', this.device.uuid); this.oneSignal.getIds() .then((id) => { console.log(id); }) this.oneSignal.endInit();
I’m doing something wrong? If not, what is the best alternative to do this (maybe another plugin)?
Thank you
Posts: 1
Participants: 1