Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Missing Constraint Autolayout Warning

Tags:

ios

autolayout

I have a project and I used to add constraints with xcode interface builder. In a specific case I needed to add some constraints in my controllers source. My question is that although I have the result I was seeking for, xcode returns missing constraints warnings.

Is this something I should handle? I mean, I add constraints in the source code. Show I do something to update my storyboard in order to be aware of these?

like image 263
raistlin Avatar asked Sep 16 '25 21:09

raistlin


1 Answers

You don't need to handle these, but if you want to get rid of the warnings, you can add placeholder constraints in IB, that are removed at build time, so you can replace them with code generated constraints. When you select a constraint, and go to the Attributes Inspector, you will see a box, "Placeholder -- Remove at build time". If you check that box, those constraints are automatically removed.

like image 170
rdelmar Avatar answered Sep 19 '25 15:09

rdelmar