Candylicious iOS Tips

Menu & Search

Fastest way to use Auto Layout in code

June 10, 2016

Raise your ✋ if you hate adding views and setting up NSLayoutConstraints in code. If your hand is in the air, you’re missing out on a great feature Apple introduced in iOS 9, which most developers don’t know about. I’ll show you how to center a view in two elegant lines of code. But first, let me remind […]

Continue Reading

A practical MVVM example in Swift – Part 1

May 2, 2016

The good ol’ MVC pattern has been around for a while. The acronym usually stands for Model-View-Controller, but in iOS, we’re mostly referring to Massive-View-Controller and we all know why. 1000+ line view controllers are not uncommon. And why’s that? Probably because it’s too easy to write messy view controllers. Even Apple is famous for not […]

Continue Reading

Supporting links in text

April 24, 2016

If you’ve encountered a use case where you need a tappable link in a label, you might have been a bit confused. See, UILabels do not natively support tappable links. Luckily, there are at least two workarounds at your service: 1. UITextView and NSAttributedString You might think it’s an overkill to use a UITextView instead […]

Continue Reading

Which iOS versions should you support?

February 9, 2016

You might find yourself in a situation where your client is pushing for support of an older version of iOS. They think they will reach the maximum number of users thus increasing their chances of success. They are wrong and here’s how you can convince them otherwise. (Big) target audience The only (even remotely capable) […]

Continue Reading

Self-sizing UITextView in a UITableView using Auto Layout (like Reminders.app)

February 7, 2016

I’ve covered dynamically sized UILabels in tables in a previous post but this time, we’re taking a look at self-sizing UITextViews, similar to how the native Reminders app works. Pretty exciting! Now, I’ve seen a lot of developers make the mistake of overcomplicating their code with custom text size calculations etc. Don’t do that! You do not […]

Continue Reading
Page 1 of 3 1 2 3
Type your search keyword, and press enter to search