There is a xib file with a custom UINavigationBar setting (everything is connected in the xib file). There is a swift file with an additional bar configuration. In AppDelegate I do the following:

 let nc = UINavigationController(navigationBarClass: GeneralNavigationBar.self, toolbarClass: nil) nc.setViewControllers([ProfileTableViewController()], animated: false) let mainViewController = UITabBarController() mainViewController.viewControllers = [nc] window?.rootViewController = mainViewController 

Having started the project I do not get the expected result, I see the default white navigation bar

    1 answer 1

    What is the custom navBar attached to? It must be made and tied to each controller. In each controller, you load xib and add it to vc.view .

    Before this, you hide navigationController.navigationBar with .navigationBarHidden = YES;