How to add Carthage support in existing CocoaPod project

I’ve finally found some free time to review the contributions on AHDownloadButton repo and prepare a new release. Before releasing a new version I wanted to add support for Carthage, because the project is currently only supporting CocoaPods. Carthage is a great lightweight dependency manager and if you haven’t used it yet, I suggest you read up on it on. Even though I’ve used Carthage...

Determining the content size of a WKWebView

In one of my recent projects, I had to use a web view to display an HTML string with local CSS and custom font. The web view had to be embedded inside a scroll view along with a couple of other views. It also had to have a height adjusted to the content it was displaying. My goal was to create something like this: I...

Replicating the App Store download button

With the release of iOS 11, Apple introduced a completely redesigned App Store app with greatly improved UI. Among many features and improvements, one thing that I found interesting was the redesigned download/purchase/update button. I’ve been working in my spare time on implementing the download button. After a bit of experimenting, I implemented a working version. I only needed a couple more days to clean...

New features in Swift 4.2

Yesterday, Apple officially released the latest version of Swift programming language - Swift 4.2. It is a major release with a lot of improvements that include faster build times and features aimed towards removing boilerplate code and improving efficiency. It is also a significant step towards ABI stability planned for Swift 5. There were many proposals that were accepted in this release. In this blog...

Animated launch screen using a GIF in iOS

There was a question on a Slack channel for iOS developers on how to implement an animated launch screen using a GIF image since Apple doesn’t allow GIF images in launch screens. I answered the question with a brief explanation on how it could be implemented and how the user could get the impression that the launch screen is animating. In this blog post, I...