Last active
July 29, 2016 09:12
-
-
Save m-etka/41a9530e8aa91eb36336ae147f753cb8 to your computer and use it in GitHub Desktop.
Background Threads in Swift
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
// Special thanks to thatthinginswift.com (https://thatthinginswift.com/background-threads/) | |
dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), { | |
// do some task | |
dispatch_async(dispatch_get_main_queue(), { | |
// update some UI | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment