WidgetKit - Is it possible for a WidgetConfigurationIntent Struct to have an extra parameter in its initializer?
18:28 05 Nov 2025

Been playing around with AppIntentConfiguration in WidgetKit and was wondering if I can have a parameter being passed in the intent structure? Below is what I'm trying to achieve, but I keep getting this error: Cannot convert value of type 'SelectCharacterIntent' to expected argument type 'SelectCharacterIntent.Type'. Any help would be great!

struct CharacterDetailWidget: Widget {
        var body: some WidgetConfiguration {
            AppIntentConfiguration(
                kind: "com.mygame.character-detail",
                intent: SelectCharacterIntent(WidgetStyle: String).self,
                provider: CharacterDetailProvider(),
            ) { entry in
                CharacterDetailView(entry: entry)
            }
            .supportedFamilies([.systemSmall, .systemMedium, .systemLarge])
        }
    }
ios swiftui widgetkit