Responding to Notifications
The extension delegate also handles local and remote notifications for watchOS apps. The methods to implement in the protocol mirror those for responding to notifications on iOS and for good reason—one of the primary use cases of the Apple Watch is to act as a conduit for iOS app notifications—whether or not the app has an Apple Watch--specific app. When the user’s iPhone is locked and the Apple Watch is unlocked, all notifications are routed to the watch by default. The real power of notifications on the watch comes with actions associated with these notifications; as you can see in this screenshot, a notification can include buttons that perform actions when the user selects them. When a notification comes in, you ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access