Search code examples
iossdwebimage

Some problems with SDWebImage


When I used the method load image, after the image gets downloaded, it does not show until I select or scroll the cell, but if I don't set the placeholderImage to nil, it works well. I don't know what's wrong with. Here's my code:

[cell.imageView sd_setImageWithURL:(my url) placeholderImage:nil];

Some problems with SDWebImage


Solution

  • It's weird, but you can try [cell setNeedsLayout]; after you set the image to reload all the cell views.

    I guess you have all the calls inside tableView:cellForRowAtIndexPath: