Contents

AnyView

A type-erased view.

Declaration

@frozen struct AnyView

Overview

An AnyView allows changing the type of view used in a given view hierarchy. Whenever the type of view used with an AnyView changes, the old hierarchy is destroyed and a new hierarchy is created for the new type.

Topics

Creating a view

See Also

Supporting view types