I've been trying to implement Apple Music like transparent navigation bar for pushed view controller. There are a lot of solutions on Internet saying place the code below into viewDidLoad:
navigationController?.navigationBar.setBackgroundImage(UIImage(), for: .default)
navigationController?.navigationBar.shadowImage = UIImage()
But the thing is that it only works for root controller, e.g. UITableViewController with a list of items. When I tap on an item and open it's details I expect to see transparent navigation bar, but after appearing it becomes solid (not even translucent). Even setting barTintColor does not help.
What am i doing wrong? Or is it a known issue in iOS 11? It used to work before...

