'any guess why I can't get arView's width and height...?

struct ARViewContainer:UIViewRepresentable{

func makeUIView(context: Context) ->  CustomARView {
    var arView = CustomARView(frame: .zero)
    arView.session.delegate = context.coordinator
    context.coordinator.view=arView
    context.coordinator.width = Int(arView.bounds.width)
    context.coordinator.height=Int(arView.bounds.height)
    wwidth=Int(arView.bounds.width)
    hheight=Int(arView.bounds.height)
    print("makeui \(arView.bounds.width)")

my code is...as above. I think it's simple but don't know why I can't get width and height of arview



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source