If you try to measure www.barnesandnoble.com with the lighthouse API, it always measures the performance for m.barnesandnoble.com which is the mobile site. I've tried this using the lighthouse chrome addin and with Chrome's debugging tool's "Audit" feature.
Thanks for raising this @mjara74. The extension and Audits panel are restricted to mobile emulation/evaluation currently. As a workaround you can use the CLI with the flags --disable-network-throttling --disable-cpu-throttling --disable-mobile-emulation
Duplicate of #2838
Hi @patrickhulce - what's the equivalent Node for desktop browsing - in my settings file I have
module.exports = {
headless: false,
args: [
'--remote-debugging-port=9222',
'--disable-device-emulation',
'--disable-network-throttling',
'--disable-cpu-throttling'
]
};
yet when I run lighthouse it returns to the nexus 5x user-agent (and the mobile site version)
var report = await lighthouse (currentPage, settings, null);
@ashoon that settings object looks suspiciously like puppeteer options, not Lighthouse flags :)
you'd need to add disableDeviceEmulation: true to your LH flags/settings object to browse as desktop
Most helpful comment
@ashoon that
settingsobject looks suspiciously like puppeteer options, not Lighthouse flags :)you'd need to add
disableDeviceEmulation: trueto your LH flags/settings object to browse as desktop