【问题标题】:How do I force Chrome DevTools Audits to use desktop (fullscreen) emulation?如何强制 Chrome DevTools Audits 使用桌面(全屏)仿真?
【发布时间】:2018-12-16 16:17:21
【问题描述】:

我想对我的网站进行性能审核:桌面,没有限制网络,没有限制 CPU。

我正在使用 Google Chrome 的 DevTools 的审核选项卡并选择以下选项:

  • 设备:桌面
  • 审核:绩效
  • 限制:无限制
  • 清除存储(选中)

我的 chrome 版本:

Google Chrome is up to date
Version 71.0.3578.98 (Official Build) (64-bit)

根据“审核”标签,我在 Chrome 中的 Lighthouse 版本是 3.2.0

点击Run audits按钮后,报告生成,并包含以下运行时设置

URL: https://example.com/
Fetch time: Dec 15, 2018, 11:18 PM PST
Device: Emulated Nexus 5X
Network throttling: 150 ms TCP RTT, 1,638.4 Kbps throughput (Simulated)
CPU throttling: 4x slowdown (Simulated)
User agent (host): Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36
User agent (network): Mozilla/5.0 (Linux; Android 6.0.1; Nexus 5 Build/MRA58N) AppleWebKit/537.36(KHTML, like Gecko) Chrome/71.0.3559.0 Mobile Safari/537.36
CPU/Memory Power: 998

那么我该如何强制使用我的设置,以便正确审核桌面?

编辑:上游验证为 Chrome 错误:

https://bugs.chromium.org/p/chromium/issues/detail?id=914387

【问题讨论】:

    标签: google-chrome google-chrome-devtools pagespeed lighthouse


    【解决方案1】:

    这似乎是 Google Chrome 的错误,请参阅下面的引用和参考:

    We've found the culprit, but it'll require a Chrome-side fix.
    
    Note that it's not just Mobile/Desktop, but the throttling settings and clear storage options are also being ignored at the moment which would explain all of the performance score differences.
    -- patrickhulce, paulirish
    

    参考:https://github.com/GoogleChrome/lighthouse/issues/6772#issuecomment-446626154

    上游错误:https://bugs.chromium.org/p/chromium/issues/detail?id=914387

    Verified the fix on Mac 10.12.6, Windows-10 & Ubuntu 17.10 on Chrome version #73.0.3640.0 as per the comment#0
    

    批准用于 Chrome M72 分支,3626

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2014-12-05
      • 2014-05-08
      • 2018-02-19
      • 1970-01-01
      • 2016-03-23
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多