Was ich getan habe? /> Cordova
Code-Snippet:
importieren {localnotifications, elocalnotificationTriggerUnit} aus '@ionic-nativ/local-nicht-nicht-Nichts/ngx'; /> Konstruktor (Private LocalNotifications: LocalNotifications) {}
// Aufrufen Sie diese Methode, um eine wiederholende Benachrichtigung zu senden
sendIntervalnotification () {
Code: Select all
this.localNotifications.schedule({
id: 1,
title: 'Reminder',
text: 'This is your scheduled notification',
trigger: {
every: { minute: 1 }, // runs every 1 minute
count: 10 // total number of times to repeat
},
foreground: true, // show when app is foregrounded
lockscreen: true // try to display on lockscreen
});
}
Frage:
Wie kann ich wiederholt/intervall lokales Benachrichtigungen sowohl auf iOS als auch auf iOS und Android funktionieren, selbst wenn die App im Hintergrund oder das Gerät eingesperrt ist?>