using the image assigned to userprofile in firebase and attachine it to profile page

后端 未结 1 1810
伪装坚强ぢ
伪装坚强ぢ 2021-01-28 06:49

I have been looking online everywhere to help me out here but I cannot figure this out. The code below says that allows for the image to get stored in the firebase database when

相关标签:
1条回答
  • 2021-01-28 07:14

    The last edit to the question asks this

    Now how do I use this in my viewController to actually show the image on the imageView???

    This indicates you have a viewController that contains an imageView as you're asking how to assign the downloaded image to that imageView.

    The image is downloaded here in your code

    static func downloadImage(withURL...
            var downloadedImage:UIImage
            if let data = data {
                downloadedImage = UIImage(data: data)
    

    so a single line of code following that will take the downloadedImage and display it in the imageView

    self.myImageView.image = downloadedImage
    
    0 讨论(0)
提交回复
热议问题