const img = new Image();
img.setAttribute("crossOrigin", 'Anonymous');
img.src = url + '?t=' + new Date().getTime();
imgBg.onload = function() {}
请求路径后面增加new Date().getTime(),防止浏览器重复请求相同资源

相关文章:

  • 2021-07-30
  • 2021-11-30
  • 2022-12-23
  • 2022-12-23
  • 2022-01-14
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-02-23
  • 2021-07-15
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-10-30
相关资源
相似解决方案