i\'ve been trying to remove the navigationBars border without luck. I\'ve researched and people seem to tell to set shadowImage and BackgroundImage to nil, but this does not
Luca Davanzo's answer is great, but it does not work in iOS 10. I altered it to work in iOS 10 and below.
for parent in navigationController!.view.subviews {
for child in parent.subviews {
for view in child.subviews {
if view is UIImageView && view.frame.height == 0.5 {
view.alpha = 0
}
}
}
}
You can also extend UINavigationController and call this off of that. removeFromSuperview()
on the line will not work on iOS 10, so I just set the alpha to 0 so this one call is compatible everywhere.