Xcode color scheme

The official MABDEV Xcode color scheme !

What I tried to achieve:

  1. Better distinguish local and instance variables with color and italic ( I don’t like to use “self” when it’s unnecessary).
  2. Blue strings because red should be for errors.
  3. Bold types names ( more like Eclipse )

You’ll need the Consolas Font for a better result.

MABDEV Xcode Color scheme download

Hope you like it !

Cheers,

MAB

URLSession and the missing policy

Hi !

Usually you want to make your app behave better under poor network conditions but you also want it to fetch the latest data when available.  In terms of caching policy it would mean : “loadFromWebElseUseCache”

Unfortunately it does not exists.  What’s available is :

Some of them aren’t even implemented !  I solved the problem by using two different URLSession :

Hope you like it !

Cheers,

MAB

Good vibrations

Hi !  I was recently asked to make the iPhone vibrate while using the app (not by notification).  It’s been a while since I had to do it and back then it was in Obj-C. Here’s how to achieve it in Swift:

Cheers,

MAB