RealityView
RealityView can used developing only for IOS 18+, IPadOS 18+, MacOS15+ and VisionOS 1+. struct ModelExample : View { var body: some View { RealityView { content in if let robot = try? await ModelEntity (named: "robot" ) { content.add(robot) } Task { // Asynchronously perform any additional work to configure // the content after the system renders the view. } } } } The above is a sample code sourced from apple developer documentation. Here the struct ModelExample cornforms to data type view. The realityview behaves as any other view like Text(), Button() or EmptyView(). It accepts most of the modifiers of all common views. realityview is overloaded, hence we have three basic variations. 1. RealityView{ Content in // necessary 3D content } 2. RealityView { content in ...