How can I remove border bottom of UINavigationBar?
问题 I want to remove the bottom border from UINavigationBar , but I don't know how to remove it. 回答1: Actually, that is the shadow of the navigation bar. To get rid of it, just set it to an empty image: navigationController.navigationBar.shadowImage = UIImage() Note: You must set it to an empty UIImage() ; nil won't work for some reason. 回答2: You need to set a custom shadow image to show instead of the default one. Note: a custom background image must also be set. navController.navigationBar