frostbelt

特例:

当$(window).width()无效时

/* 出现时机: iframe内嵌子页面在加载过程中取不到$(window).width(),非必现,机率大概1 / 20 */

可用以下方式获取屏幕宽度:

window.screen.width /= window.devicePixelRatio

分类:

技术点:

相关文章:

  • 2021-08-28
  • 2021-09-01
  • 2021-12-09
  • 2021-11-17
  • 2021-09-23
  • 2022-03-02
  • 2022-02-18
猜你喜欢
  • 2021-12-22
  • 2022-01-02
  • 2021-07-24
  • 2021-12-26
  • 2022-12-23
  • 2021-11-30
  • 2021-11-30
相关资源
相似解决方案