Post

Replies

Boosts

Views

Activity

Reply to Implementing Apple Watch Widget Complications
Your problem is this code: func getTimeline(in context: Context, completion: @escaping (Timeline<SimpleEntry>) -> Void) { } All widgets run off of a timeline. It essentially tells the OS what particular widget to show when. You provided no Timeline in return, so the OS thinks you do not want to show anything. Something as simple as this: func getTimeline(in context: Context, completion: @escaping (Timeline<SimpleEntry>) -> Void) { let timeline = Timeline(entries: entries, policy: .never) completion(timeline) } should be enough to get you going. This is pretty basic stuff for widgets. I would recommend doing Apple's Widgets Code-along from WWDC 20.
Feb ’24