Skip to content

fix(browsers): correctly import yargs for esm module #13249

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

Merged
merged 2 commits into from
Oct 30, 2024

Conversation

chubei-urus
Copy link
Contributor

@chubei-urus chubei-urus commented Oct 30, 2024

What kind of change does this PR introduce?

This PR changes the way to import yargs.

Did you add tests for your changes?

No, would be happy to know how to add a test for it.

If relevant, did you update the documentation?

No doc update is needed.

Summary

This is to work around yargs/yargs#2418, which prevents any application that uses puppeteer from being built using single file bundlers like ncc.

Does this PR introduce a breaking change?

No.

Other information

Copy link

google-cla bot commented Oct 30, 2024

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@OrKoN OrKoN added the full-ci label Oct 30, 2024
Copy link
Collaborator

@Lightning00Blade Lightning00Blade left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, please run npm run format to fix the lint issue.

@chubei-urus
Copy link
Contributor Author

@Lightning00Blade Thank you! Pushed the format fix patch.

@Lightning00Blade Lightning00Blade changed the title fix(esm): correctly import yargs esm module fix(browsers): correctly import yargs esm module Oct 30, 2024
@Lightning00Blade Lightning00Blade changed the title fix(browsers): correctly import yargs esm module fix(browsers): correctly import yargs for esm module Oct 30, 2024
@Lightning00Blade Lightning00Blade merged commit 694fef9 into puppeteer:main Oct 30, 2024
21 checks passed
@release-please release-please bot mentioned this pull request Oct 28, 2024
@release-please release-please bot mentioned this pull request Jan 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants