downloadTask(with:completionHandler:) vs. dataTask(with:completionHandler:)

This is not just about where files are stored on the host device, it’s rather more than that. Although these two instance methods seem similar, we need to know the difference in order to produce great software.

Read on for the details, and there is a rather nice GitHub link at the bottom to help you with practical examples. Isn’t that nice?

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store