简体   繁体   中英

When navigating back in navigation controller view doesn't load

I have weird situation and have no clue how to debug it. I load three viewControllers in navigation controller. When Im navigating back from there second and first ViewController doesn't display anything just white screen I added print methods everywhere in lifecycle methods and it seems that it loads views but anyway they not visible. What could be the problem?

Yep It's weird, There maybe some code which do something with your view on such events like:

override func viewDidDisappear(_ animated: Bool) {
    super.viewDidDisappear(animated)
    // remove some subviews or change constraints.
}

override func viewWillDisappear(_ animated: Bool) {
    super.viewWillDisappear(animated)
    // remove some subviews or change constraints.

}

Please send us a code of the view controller which has the problems and code how exactly you show the controller.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM