I can refactor, to avoid having to do this, but what can I use as the var type in the snippet below:
var mySwiftUIView: __________?
if shouldUseFancyView() {
mySwiftUIView = FancyView(param: paramValue)
} else {
mySwiftUIView = PlainView(param: otherParamValue)
}
let hostingView = NSHostingView(rootView: mySwiftUIView)
In the API, NSHostingView's rootView appears to be of type Content, but it's not clear to me what Content refers to.
thanks in advance,
Mike