I'm used to defining in the application appDelegate the viewController with which the application starts, for example:
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {
//inicializar la aplicación
window = UIWindow(frame: UIScreen.main.bounds)
let mainVC = MainVC()
let navigationController = UINavigationController(rootViewController: mainVC)
navigationController.setNavigationBarHidden(true, animated: true)
window?.rootViewController = navigationController
window?.makeKeyAndVisible()
return true
}
However, I have found projects (in cocoapods especially) that have nothing defined in the appDelegate and the application starts in a specific Controller, even though there is more than one in the same route.
What is the execution rule of the ViewController default? Is there something inside the controller that I am omitting and that allows to run as default controller?