I'm a beginner to programming and have just added a custom tab bar to allow navigation throughout the app. However, since I have added the property wrappers to let this happen I get the error:
'app does not conform to protocol 'App' '.
It forces me to add the init() protocol stubs but I cannot seem to get it to work- so I can run by code without the error 'Return from initializer without initializing all stored properties'. I've tried everything but still it won't go away.
I updated Xcode last night if that is relevant and the error has only come on as I started working on my project today.
Here's where the error is coming from
import SwiftUI
import Firebase
@main
struct PhotoApp: App {
init () {
FirebaseApp.configure()
}
@StateObject var viewRouter: ViewRouter
var body: some Scene {
WindowGroup {
ContentView().environmentObject(viewRouter)
}
}
}