I tried using .ignoresSafeArea()
, but did not work.
There were not a padding in iOS 16 and early versions around the content view.
struct CommonDailyEyeTipsWidget: Widget {
let kind: String = "CommonDailyEyeTipsWidget"
init() {
//setup firebase
FirebaseApp.configure()
}
var body: some WidgetConfiguration {
StaticConfiguration(kind: kind, provider: Provider()) { entry in
Rectangle()
.foregroundStyle(Color.primary)
.ignoresSafeArea() // Does not work
.containerBackground(.accent, for: .widget)
}
.contentMarginsDisabled()
.configurationDisplayName("My Widget")
.description("This is an example widget.")
}
}