can I make a live activity timer with formatting so it is only showing HH:mm ?

Generated on 7/31/2024

1 search

Yes, you can create a live activity timer with formatting to show only hours and minutes (HH:mm). In the session What’s new in SwiftUI, it is mentioned that text now has additional formats for the display of live times and dates that work great in widgets and live activities. These formats include date references, date offsets, and timers, and each format is deeply customizable down to its components.

For more detailed guidance on building and customizing live activities, you might also find the session Extend your app’s controls across the system helpful, where a productivity timer control is built and refined.

Relevant Sessions:

  1. What’s new in SwiftUI
  2. Extend your app’s controls across the system