Avatar ·

How to remove the bottom line (1px) from UINavigationBar in iOS

Hi everyone! I'm a beginner iOS developer, and I'm having a problem with the navigation bar design. I want to make UINavigationBar completely transparent, without the standard gray line at the bottom (this line is often called the "1px bottom line" or shadow image). I've tried several methods, but nothing works. Here's my current Swift code where I'm trying to remove this line: ```swift override func viewDidLoad() { super.viewDidLoad() navigationController?.navigationBar.setBackgroundImage(UIImage(), for: .default) navigationController?.navigationBar.shadowImage = UIImage() navigationController?.navigationBar.isTranslucent = true } ``` But the line still remains! I also tried setting `shadowImage` to nil, but that didn't help either. I also noticed that if