Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Replace arrgv with args-tokenizer #3364

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

TrySound
Copy link
Contributor

@TrySound TrySound commented Dec 29, 2024

Recently published args-tokenizer package. We use it at Webstudio for parsing cURL on paste. Also used at https://github.com/antfu-collective/bumpp.

There are a few benefits

  • published with type definitions
  • parser is forgiving to unclosed quotes which can be more user friendly
  • actively supported, arrgv last release was 5 years ago

The package also is esm only but used only in CLI so should not be a problem with commonjs. Though I can add cjs support if necessary.

https://github.com/TrySound/args-tokenizer

Recently published args-tokenizer package. We use it at Webstudio for
parsing cURL on paste. Used at
https://github.com/antfu-collective/bumpp.

There are two benefits
- published with type definitions
- parser is forgiving to unclosed quotes which can be more user friendly

The package also is esm only but used only in CLI so should not be a
problem with commonjs. Though I can add cjs support if necessary.

https://github.com/TrySound/args-tokenizer
@sindresorhus
Copy link
Member

I don't think silently forgiving invalid input is an improvement.

@TrySound
Copy link
Contributor Author

Will "strict" option work for you? I can add it

@TrySound
Copy link
Contributor Author

Upgraded to new strict by default version and reverted test changes

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants