Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
Jason Gong
4,537 PointsUse Storyboard or Pure Code to create UI
In coding in IOS, googling for answers seems to provide a pretty split view on whether to use the storyboard to style, link, set constraints, etc for parts of the app. I've always found it easier to use the storyboard since you can see it and thats what TreeHouse uses in the tutorials.
But should I learn how to do it by code?
Will there be things I encounter as I do more advanced things that will be better done in code?
1 Answer
Eduardo Rojas
4,084 Pointsill tell you a personal experience:
I'm finishing a game and i made it using UIView and now Sprite Kit (which later i discovered it was a error), but why it was a error? well if Ii wanted to add a character aligned to something its really different in code than in the storyboard, so the objects may move making your app crash, if you are having a single view application that shows info or images i think the storyboard is a good way to go, but if you are trying to make something more complex like a game ill suggest you try using spriteKit or do it programmatically, in personal opinion you should try learning to code the most you can
Erion Vlada
13,496 PointsErion Vlada
13,496 PointsFrom what iv research there is no one best way to do it. You can even mix and match, depending on what suits. Learning to do it by code is defiantly a win though, you will understand much more or how things are actually put together.
Apple is pushing Storyboards a lot, if you open some of their in house apps, they are made with xib files, so that tells you a lot.