Skip to content
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

Add browser arguments option #138

Merged
merged 1 commit into from
Feb 5, 2024
Merged

Conversation

nielthiart
Copy link
Contributor

@nielthiart nielthiart commented Dec 18, 2023

Ref #137

This change adds --browser-args option to the CLI, then passes a list of arguments to the browser launch function.

The argument can be included multiple times to list multiple arguments.

This enables users to pass flags to the browser, such as --font-render-hinting=none, --disable-gpu, etc.

These flags can have an effect on how screenshots are captured across different platforms.

Detailed reason here: #137


📚 Documentation preview 📚: https://shot-scraper--138.org.readthedocs.build/en/138/

Ref simonw#137

This change adds `--browser-args` option to the CLI, then passes a list of arguments to the browser launch function.

The argument can be included multiple times to list multiple arguments.

This enables users to pass flags to the browser, such as `--font-render-hinting=none`, `--disable-gpu`, etc.

These flags can have an effect on how screenshots are captured across different platforms.

Detailed reason here: simonw#137
@simonw
Copy link
Owner

simonw commented Feb 5, 2024

This is a neat change. I'm going to merge as-is, but I'm not a fan of capitalized short options so I'll remove the -B and keep it as just --browser-args.

I'll also rename --browser-args to just --browser-arg for consistency with my other tools.

@simonw simonw merged commit 3df5fa0 into simonw:main Feb 5, 2024
2 checks passed
simonw added a commit that referenced this pull request Feb 5, 2024
simonw added a commit that referenced this pull request Feb 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants