When starting the app using the SwiftUI App protocol, alerts presented from NStack are not displayed in app. If you initialise your app with a UIHostingController in a UIWindow, it works as expected.
Eg;
@main
struct DemoApp: App {
@UIApplicationDelegateAdaptor(AppDelegate.self) var appDelegate
// MARK: Scenes
var body: some Scene {
WindowGroup {
AppCoordinatorView(coordinator: appDelegate.coordinator)
}
}
}
When starting the app using the SwiftUI
App
protocol, alerts presented from NStack are not displayed in app. If you initialise your app with a UIHostingController in a UIWindow, it works as expected.Eg;
Does not work
Works as expected.
I suspect its something to do with using SwiftUI instead of UIKit and UIWindow specifically but not entirely sure.