Which takes higher priority? Code or Storyboard?

350 Views Asked by At

I've been messing with my UINavigationBar color in my iOS App written in Swift. When doing this, I know there are two ways to set the color - Either in Storyboard or in my Appdelegate code. Which of the two takes higher priority?

This applies to more than just UINavigationBars of course, so I thought it would be helpful to many newbies like me.

1

There are 1 best solutions below

1
On BEST ANSWER

If for example you set a color in Interface Builder for an UINavigationBar and you also change the color in code for the same UINavigationBar, the color defined in code will be used.