let home = homeViewController()
let rootNav = UINavigationController(rootViewController: home)
window?.rootViewController = rootNav
window?.makeKeyAndVisible()
let second = SecondViewController()
home.navigationController?.pushViewController(second, animated: false)
let third = ThirdViewController()
home.navigationController?.pushViewController(third, animated: false)
After the above is executed, the viewdidload and other related lifecycle methods in the SecondViewController are not executed。
Except for iOS18, other versions don't have this problem, so it's not a bug in iOS18, or iOS18 has optimized UINavigationController