Monday, July 29, 2019

Thursday, July 25, 2019

How to add buttons to the navigation bar

http://swiftdeveloperblog.com/code-examples/create-uibarbuttonitem-programmatically/

NOTE:
remember to pass in a navigation controller

 let navController = UINavigationController(rootViewController: viewController) // Creating a navigation controller with VC1 at the root of the navigation stack.
        
        DispatchQueue.main.async {
        
            self.navigationController?.visibleViewController?.present(navController, animated: true, completion: nil)
           

        }