-
-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Lighthouse Reports Showing Mobile Layout Despite Desktop Configuration File #100
Comments
and I have the same situation |
is any solution to solve this problem? |
@qakos I've used the following await playAudit({
opts: {
formFactor: "desktop",
screenEmulation: { disabled: true },
}, |
@vito-techietalent thank you for your solution. For now in report showing tablet version of page, but still not desktop. Which version of playwright-lighthouse do you use? |
I added 'opts' settings in my code. As I understand, for lighthouse my page opened in a viewport width less than 1024px, despite the fact that in the playwright settings of the project, the viewport 1920x1080 is specified. But in playwright ui-mode page opened with viewport as I need. |
@qakos Regarding screen size, on the await playwright.chromium.launch({
args: ["--remote-debugging-port=9222", "--window-size=1920,1080"],
}); Source https://stackoverflow.com/questions/77278023/how-to-maximize-the-window-size-in-playwright |
@vito-techietalent Thank you! This solution helped me to solve my problem! |
Lighthouse by defaults to the mobile layout. I am passing the lighthouseDesktopConfig file, located at
lighthouse/core/config/lr-desktop-config
from the node_modules to configure the tests for the desktop layout. However, the reports are still reflecting the mobile layout. Even with the desktop configuration being passed.on file specified, the issue persists.
The text was updated successfully, but these errors were encountered: