One Logo Pool Ball
WidgetKit · IOS API REFERENCE

WidgetRelevanceGroup

struct · iOS 18.0+ · SDK 27.1

struct WidgetRelevanceGroup

A type for configuring widget behavior in the watchOS Smart Stack. Use `WidgetRelevanceGroup` alongside ``WidgetRelevanceAttribute`` to tell the system how it should group your widgets in the watchOS Smart Stack. The system may provide a default grouping mechanism for widgets in the Smart Stack; for example, per-app grouping. Creating a relevance group and choosing the `.ungrouped` option opts out of default grouping behavior. For additional information about widgets in Smart Stacks, refer to <doc:Widget-Suggestions-In-Smart-Stacks>.

Members (3)

static · iOS 18.0+

named

TypeScript
static named(name: string): WidgetRelevanceGroup
Swift declaration
static func named(_ name: String) -> WidgetRelevanceGroup

Creates a group with the provided name. The system won't show more than one relevant widget if they are in the same. A widget group doesn't affect widgets by other apps.

get · iOS 18.0+

automatic

TypeScript
static get automatic(): WidgetRelevanceGroup
Swift declaration
static let automatic: WidgetRelevanceGroup

Specifies that the widget group should use the automatic grouping behavior provided the system.

get · iOS 18.0+

ungrouped

TypeScript
static get ungrouped(): WidgetRelevanceGroup
Swift declaration
static let ungrouped: WidgetRelevanceGroup

Don't use the system's default behavior for grouping widgets.

Skipped declarations

No declarations were skipped in this snapshot.

All WidgetKit types →