Gra*_*zor 10
找到答案
var body: some WidgetConfiguration {
IntentConfiguration(kind: kind, intent: ConfigurationIntent.self, provider: Provider()) { entry in
TestWidgetEntryView(entry: entry)
}
.supportedFamilies([.systemSmall, .systemMedium])
.configurationDisplayName("My Widget")
.description("This is an example widget.")
}
Run Code Online (Sandbox Code Playgroud)
您可以在@main函数中添加.supportedFamilies([.systemSmall, .systemMedium])
| 归档时间: |
|
| 查看次数: |
550 次 |
| 最近记录: |