Ascunderea separatorului de 1px aflat sub UINavigationBar – Swift3

Deranjant uneori, separatorul dintre View-ul principal si UINavigationBar aparut in IOS 7 poate fi scos prin adaugarea acestui cod in AppDelegate -> application: didFinishLaunchingWithOptions:

UINavigationBar.appearance().setBackgroundImage(
UIImage(),
forBarPosition: .Any,
barMetrics: .Default)
UINavigationBar.appearance().shadowImage = UIImage()

Share Button