Normally in SwiftUI, data which is owned by the view and used to render it is held in a private property marked with the @State property wrapper. This tells the system to track changes to that property so it knows when to update the view.
But... if that data never changes, and thus is marked with let
and is set via the initializer, do you still need the @State
attribute?
Additionally, since WidgetKit's views are all immutable by design (let alone ran in a completely separate/isolated process owned by the system), is there ever a case to use any of the state-related modifiers for views exclusively used in Widgets?