Change Image colour

PHOTO EMBED

Tue May 31 2022 05:47:57 GMT+0000 (UTC)

Saved by @hasnat #ios #swift #image #imagecolor #imagecolour #changeimagecolour

extension UIImageView {
  func setImageColor(color: UIColor) {
    let templateImage = self.image?.withRenderingMode(.alwaysTemplate)
    self.image = templateImage
    self.tintColor = color
  }
}
content_copyCOPY