One of the most common animations we see nowadays is the parallax effect. You see it on a lot of websites and sprinkled here and there inside of mobile applications. It’s hard to put into words why it’s so enjoyable but like flies, we’re drawn to it. That’s why today I’ll show you how to implement it programmatically inside of … Read More
Create a Paging Scroll View using NSLayoutAnchor and UIStackView
Today I wanna show you how to implement a Paging Scroll View programmatically using some cool AutoLayout APIs. You might be asking “Why do this programmatically?”. Truth is, you could do a mix of storyboard or completely in storyboard and get the same result.The reason is that in my next tutorial Adding a Parallax Effect to a UIScrollView using NSLayoutAnchor I … Read More
How to Guard your Secrets Using Git
Depending on how long you’ve been programming this might seem obvious, or odd. Recently, I’ve been playing with a few APIs and chose GitHub for version control. The problem is on GitHub (because I don’t pay) the code I push is public so how do I keep those API keys secret? The Swift community has a few answers to this … Read More
Optimizing Google Translation API calls for iOS
Recently, I started working on an app that needed the ability to translate text to different languages. That meant looking and finding the right API. I settled on using the Google Cloud Platform Translation API because of its great documentation and assumed reliability. The catch is that it’s not a free service. Google will charge $20 per 1,000,000 characters it … Read More
Getting Started with NSLayoutAnchor (Swift 4.0)
Displaying views correctly on the screen can be one of the most frustrating parts of building apps. With the addition of more screen sizes, it’s not getting any easier. Thankfully, Apple is also offering us more ways to work with auto layout. Here I’m gonna take an introductory look at the an API introduced in iOS 9, NSLayoutAnchor. I’ll show … Read More
Ternary Conditional Operator
Getting rid of if-else statements is what the ternary operator was made for. Once you learn about it you’ll be tempted to refactor all your code. But where would you look to refactor? I’m gonna take you through a quick example of what that looks like. Here’s a bit of ugly code that could be improved A LOT! We’re generating … Read More
Swift’s New #selector Syntax Sugar
The war between Swift’s strongly typed language features and stringly typed parameters took another blow with the release of Swift 2.2. Before Swift 2.2 you’d write code like this Now I don’t disagree that you and I are perfectly capable of coping and pasting the selectors name but that’s not the point. Swift is here to help reduce the amount of human … Read More
Getting Started with NSLayoutAnchor
One of the most challenge parts of creating any app is figuring out how you’re gonna lay out the views on a screen. With the addition of more screen sizes it’s not getting any easier but thankfully apple is also offering us more ways to work with auto layout. Here I’m gonna take an introductory look at the new API … Read More
What are Classes, Structs, and Enumerations?
The aim of this post will be to broadly cover topic of WHAT are classes, structs, and enumerations. I won’t be going into how or when to use them but simply how they fit into programming. I’ll be explaining why they’re used and what purpose they serve when creating a program.
How to Use Protocols and Optionals to Reuse TableViews
As a developer one of the core concepts I’ve picked up on is the importance of reusability. You should NEVER write the same line of code twice! Programming is a constant battle against complexity and that means a healthy balance between readability and fewer lines of code! Here I’ll show you how I’ve taken it a step further by reusing … Read More
- Page 1 of 2
- 1
- 2