Hello! I am very new to xcode/swift (but not to programming) and am having some trouble that I feel as though I shouldnt be having this much trouble with.
I have created a storyboard named Main.storyboard which i followed an online tutorial for creating. In this tutorial, simply selecting the parent tab bar controller and selecting the check box 'Is Initial View Controller' (which I have done) was enough to make the app open to that tab bar controller on run of the iphone simulation. However this tutorial was on an older version of xcode and the setup is somewhat different. In my version, I have the main 'startup' file
import SwiftUI
@main
struct MovieRankerApp: App {
var body: some Scene {
WindowGroup {
HomeView()
}
}
}
which controls what view is seen on open. As you can see above, it navigates to the 'HomeView' view generated on project creation (i simply renamed it to HomeView)
import SwiftUI
struct HomeView: View {
var body: some View {
Text("Hello, world!")
}
}
struct ContentView_Previews: PreviewProvider {
static var previews: some View {
HomeView()
}
}
My issue is that I dont want the app to open to the HomeView hello world page, yet I cant figure out how to change the MovieRankerApp: App file to load up my storyboard tab bar controller instead of the HomeView view. Any help is appreciated, thanks!