Suppose I have a nav controller stack with 2 view controllers: VC2 is on top and VC1 is underneath. Is there code I can include in VC1 that will detect that VC2 has just be
swift 3
override func viewWillAppear(_ animated: Bool) { super.viewWillAppear(animated) if self.isMovingToParentViewController { print("View is moving to ParentViewControll") } }