Using DispatchSemaphore to control asynchronous resources

A counting semaphore is a way of controlling access to a resource from multiple contexts. It can be also a solution for handling asynchronous methods in command line utilities. I was making a command line utility to access REST APIs recently. I needed a way to make sure that the…

How to make a progress bar for WKWebView

Progress bar is a nice way of showing users that our app is downloading content and things are progressing. The progress bar can be placed anywhere on the screen, but it is usually a thin line just under the navigation bar. We can create a progress bar programmatically and set…

Debugging Auto Layout: Unsatisfiable Contraints

When we work with auto layout we will hit an unsatisfiable constraint error at some point. The result is a view that looks somehow broken and there are a lot of text in the Xcode’s debugger window. The unsatisfiable constraint error means that there are some conflicting constraints and the…

How to keep your client happy in a software project?

The title could be also “How to record the progress of a project and keep your client on the same page with you when a project moves fast forward?”. One of the key documents in my client communication is a changelog. It’s perhaps the most important technical documentation, since it…