Initializer

init()

Creates a button toggle style.

Declaration 宣言

init()

Discussion 議論

Don’t call this initializer directly. Instead, use the button static variable to create this style:


Toggle(isOn: $isFlagged) {
    Label("Flag", systemImage: "flag.fill")
}
.toggleStyle(.button)