Hi
I’m using the push plugin through ionic services as this describes Ionic Docs - Ionic Documentation. I would like to know if the user enabled push on the device when implementing this.
Push is imported from ‘@ionic/cloud-angular’;
If I check the docs for push native it is imported from ‘@ionic-native/push’ and makes it possible for me to check it like this:
this.push.hasPermission()
.then((res: any) => {
if (res.isEnabled) { console.log('We have permission to send push notifications'); } else { console.log('We do not have permission to send push notifications'); }
});
However hasPermission() is not available through @ionic/cloud-angular, so I have no idea how to perform this check.
Any advice is much appreciated