Building our widget UI
Creating a timeline of entries is critical for our widget to provide accurate and relevant information to the user. But to do that, we also need to render the widget UI. The place where we do that is in the widget’s structure, as we saw at the beginning of this chapter in the Configuring our widget section.
Let’s see the configuration again:
StaticConfiguration(kind: kind, provider: Provider()) { entry in MyWidgetEntryView(entry: entry) .containerBackground(.fill.tertiary, for: .widget) }
As we can see, the StaticConfiguration
has a view builder that returns a SwiftUI view, and this is probably the...