init(coder:rootView:)
Creates a hosting controller object from an archive and the specified SwiftUI view.
Declaration
@MainActor @preconcurrency init?(coder aDecoder: NSCoder, rootView: Content)Parameters
- rootView:
The root view of the SwiftUI view hierarchy that you want to manage using this view controller.
Return Value
A UIViewController object that you can present from your interface.