Caching anything in iOS
In a world filled with JSON fetching apps, caching is king.
Most iOS apps are asking a server for some JSON data, transforming it and present it nicely to the user. Caching these JSON responses can be achieved with headers and the built in functionality in URLSession.
Recently, I faced a problem that I needed to cache the request instead of the response. I needed to store upload files in the background and enable the system to restore the file and information.