Instance Method インスタンスメソッド

badge(_:)

Generates a badge for the view from a text view.

Declaration 宣言

func badge(_ label: Text?) -> some View

Parameters パラメータ

label

An optional Text view to display as a badge. Set the value to nil to hide the badge.

Discussion 議論

Badges are only displayed in list rows and tab bars.

Use a badge to convey optional, supplementary information about a view. Keep the contents of the badge as short as possible.

See Also 参照

Badges