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

to-do: investigate the viability of ParseOptions and StringifyOptions in @std/yaml #5195

Closed
6 of 17 tasks
iuioiua opened this issue Jun 29, 2024 · 2 comments
Closed
6 of 17 tasks

Comments

@iuioiua
Copy link
Contributor

iuioiua commented Jun 29, 2024

These interfaces have a lot of options, and each added option means more engineering overhead for both users and maintainers. We should go over each option and only keep the ones that have sufficient justifications for existing.

ParseOptions:

StringifyOptions (currently DumpOptions but to be updated in the next release):

@iuioiua
Copy link
Contributor Author

iuioiua commented Jul 2, 2024

ParseOptions.json allows parse() to behave similarly to JSON.parse(), in that duplicate keys are overwritten rather than throwing errors. This goes against the YAML 1.2 spec, which states that duplicate keys should cause errors (see here and here). Do we want to remove the ability to have this functionality (AKA remove ParseOptions.json) or keep it? @kt3k

@iuioiua
Copy link
Contributor Author

iuioiua commented Jul 8, 2024

This has been completed in a series of already merged PRs.

@iuioiua iuioiua closed this as completed Jul 8, 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

No branches or pull requests

1 participant