I’ve the next App Delegate file:
//
// AppDelegate.swift
// Dance Angel
//
import UIKit
@important
class AppDelegate: UIResponder, UIApplicationDelegate {
func software(_ software: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
print("✅ AppDelegate is operating!") // Only for debugging
return true
}
}
And the next SceneDelegate:
//
// SceneDelegate.swift
// Dance Angel
//
// Created by Viktoriia Danutsa on 11/2/24.
//
import UIKit
import Firebase // ✅ Import Firebase
class SceneDelegate: UIResponder, UIWindowSceneDelegate {
var window: UIWindow?
func scene(_ scene: UIScene, willConnectTo session: UISceneSession, choices connectionOptions: UIScene.ConnectionOptions) {
guard let windowScene = (scene as? UIWindowScene) else { return }
// ✅ Configure Firebase Right here
FirebaseApp.configure()
print("🔥 Firebase is efficiently configured from SceneDelegate.")
// ✅ Make sure the window is manually set
window = UIWindow(windowScene: windowScene)
window?.rootViewController = LaunchView1() // ✅ Guarantee that is your root view
window?.makeKeyAndVisible()
}
func sceneDidDisconnect(_ scene: UIScene) {}
func sceneDidBecomeActive(_ scene: UIScene) {}
func sceneWillResignActive(_ scene: UIScene) {}
func sceneWillEnterForeground(_ scene: UIScene) {}
func sceneDidEnterBackground(_ scene: UIScene) {}
}
For some cause, once I run the app, I do not see any printed messages within the console and neither any firebase logs.Anybody know why?:(
I attempted all the things: I made positive the console was exhibiting and tried to import Firebase straight within the AppDelegate as an alternative of SceneDelegate. After I run the app, all of the pages go easily from the primary one outlined in scene delegate. However, no printed messages within the logs in any respect.