Created
November 26, 2018 12:16
-
-
Save serhatsezer/5c2cd4f23e8c4e98f77bf85f6a58a0e9 to your computer and use it in GitHub Desktop.
caching URL
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let MEMORY_CAPACITY = 4 * 1024 * 1024 | |
let DISK_CAPACITY = 20 * 1024 * 1024 | |
let cache = URLCache(memoryCapacity: MEMORY_CAPACITY, diskCapacity: DISK_CAPACITY, diskPath: nil) | |
URLCache.shared = cache |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment