Create a Paging Scroll View using NSLayoutAnchor and UIStackView

Josh KuehniOS, NSLayoutAnchor, Swift, UIStackView1 Comment

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

Josh KuehnGitHub, iOS, SwiftLeave a Comment

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

Josh KuehnAlamofire, API, iOS, SwiftLeave a Comment

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)

Josh KuehniOS, NSLayoutAnchor, Swift2 Comments

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

Consuming a Rails API using Alamofire

Josh KuehnAlamofire, API, iOS, Ruby on Rails, SwiftLeave a Comment

Making network requests in today’s world is a requirement to be successful in the App Store. You might be familiar with the Apple API NSUrlSession or the Swift version UrlSession to make those requests. They get the job done but other libraries have boldly come forward to make the task easier such as Alamofire. I’ll be using Alamofire to show … Read More

Long Time No See

Josh KuehniOS, LearningLeave a Comment

Almost a year since my last post? yikes. I hate to just walk out like that and return but I have returned with many stories! Unfortunately, most will go unpublished but you’ll get a quick update on my whereabouts. We’ll begin with the birth of my Internship! Last May I took my programming skills from the class to the workplace. … Read More

Animating NSLayoutAnchor Constraints and the Pitfalls Involved

Josh KuehniOS, Learning, NSLayoutAnchor, Swift1 Comment

Correctly laying out an iPhone application sometimes feels like the 20% of a project that takes 80% of your effort/time. That’s why when Apple hit us with NSLayoutAnchor in iOS 9 I jumped on the opportunity to make life easier. If you haven’t spent time using NSLayoutAnchor check out my Getting Started with NSLayoutAnchor (Swift 3.1) article real quick and … Read More

Ternary Conditional Operator

Josh KuehnIndie, iOS, Learning, SwiftLeave a Comment

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

Josh KuehniOS, Learning, SwiftLeave a Comment

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