Hi Community, any one facing issue when calling onesignal library the script like skip from executed or not properly running? Because i facing some issue on onesignal that certain phone look onesignal no properly running so we cannot get the deviceid. certain phone working fine. i still don’t have clue what happen.
Below is my code.
await this.oneSignal.startInit(environment.onesignal.appId, environment.onesignal.googleProjectNumber);
this.oneSignal.setSubscription(true);
this.oneSignal.inFocusDisplaying(this.oneSignal.OSInFocusDisplayOption.Notification);
this.oneSignal.enableSound(true);
this.oneSignal.enableVibrate(true);
await this.oneSignal.endInit();
this.oneSignal.getIds().then((data) => {
console.log('iddddd', data);
localStorage.setItem('fcm', data.userId);
}).catch((e) => {
console.log(e);
});
thank you
1 post - 1 participant