mirror of
https://github.com/jphong1111/awesome-ios-developer.git
synced 2024-12-22 21:55:37 +07:00
update download image
This commit is contained in:
parent
2fbdac385f
commit
47520ce42b
18
README.md
18
README.md
@ -27,6 +27,7 @@
|
||||
- [Image Picker](#Image-Picker)
|
||||
- [File Manager](#File-Manager)
|
||||
- [Video Downloader](#Video-Downloader)
|
||||
- [Image Downloader](#Image-Downloader)
|
||||
- [Location Manager](#Location-Manager)
|
||||
- [API](#API)
|
||||
- [JSON](#JSON)
|
||||
@ -316,6 +317,23 @@ self.videoManager.downloadVideoLinkAndCreateAsset(text)
|
||||
```
|
||||
Good To GO 👏👏👏
|
||||
|
||||
## Image Downloader
|
||||
|
||||
There is no file for Image Downloader.
|
||||
|
||||
To download images into device, only thing is this
|
||||
|
||||
```swift
|
||||
if let data = try? Data(contentsOf: urls),
|
||||
let image = UIImage(data: data) {
|
||||
UIImageWriteToSavedPhotosAlbum(image, nil, nil, nil)
|
||||
}
|
||||
```
|
||||
> UIImageWriteToSavedPhotosAlbum will take care it to download to device.
|
||||
> For more info go [here](https://www.hackingwithswift.com/example-code/media/uiimagewritetosavedphotosalbum-how-to-write-to-the-ios-photo-album)
|
||||
|
||||
Good To GO 👏👏👏
|
||||
|
||||
## Location Manager
|
||||
|
||||
- [Location Manager](https://github.com/jphong1111/Useful_Swift/tree/main/Helper/LocationHandler/LocationManager.swift)
|
||||
|
Loading…
Reference in New Issue
Block a user