evgenyneu / moa

An image download extension of the image view written in Swift for iOS, tvOS and macOS.
MIT License
333 stars 45 forks source link

Placeholder image in moa? #4

Closed johncodeos closed 8 years ago

johncodeos commented 8 years ago

Hi, Moa has the feature to add placeholder image until image download complete ?

evgenyneu commented 8 years ago

Hi @JEKos, good question. Moa does not have any specific code for that. However, it can be done by setting a placeholder image to the image view which will be replaced by the image from the network when it arrives. For example:

imageView.image = placeholderImage
imageView.moa.url = "https://site.com/image.jpg" 
johncodeos commented 8 years ago

Thanks!