getting some things working with navigation and auth but not updating environment variable yet

This commit is contained in:
talksik
2021-12-14 14:49:17 -08:00
parent f321e983b2
commit 0fb003b556
5 changed files with 43 additions and 106 deletions
+9 -12
View File
@@ -13,22 +13,19 @@ import GoogleSignIn
struct nirvana_iosApp: App {
@StateObject var authSessionStore: AuthSessionStore = AuthSessionStore()
@UIApplicationDelegateAdaptor private var appDelegate: AppDelegate
var body: some Scene {
init() {
self.setupAuth()
}
var body: some Scene {
WindowGroup {
ContentView().environmentObject(authSessionStore)
}
}
}
}
class AppDelegate: NSObject, UIApplicationDelegate {
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey : Any]? = nil) -> Bool {
FirebaseApp.configure()
return true
}
func application(_ application: UIApplication, open url: URL, options: [UIApplication.OpenURLOptionsKey: Any]) -> Bool {
return GIDSignIn.sharedInstance.handle(url)
extension nirvana_iosApp {
private func setupAuth() {
FirebaseApp.configure()
}
}