How to check for broken images in React JS

后端 未结 5 794
忘了有多久
忘了有多久 2020-12-05 19:25

I\'m writing a module that takes article data from json and shows a large image over the article text, a hero module as they say.

I\'ve got the data and have set it

5条回答
  •  孤街浪徒
    2020-12-05 20:15

    According to my understanding you want to see broken images. you should call a method in onError attribute. Check this jQuery/JavaScript to replace broken images

提交回复
热议问题