-
-
Notifications
You must be signed in to change notification settings - Fork 776
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
[writer]Surround string by double quote instead of simple #290
Labels
Comments
There's no settings for this at the moment. The dumper tries to choose "minimal" possible scalar style to represent each particular string. Ability to specify preferred scalar styles would be nice addition though. Contributions on this matter are welcomed. |
Okay thanks for the answer, will see if i can contribute. |
jpb
added a commit
to jpb/js-yaml
that referenced
this issue
Oct 29, 2018
jpb
added a commit
to jpb/js-yaml
that referenced
this issue
Oct 29, 2018
jpb
added a commit
to jpb/js-yaml
that referenced
this issue
Oct 29, 2018
jpb
added a commit
to jpb/js-yaml
that referenced
this issue
Oct 29, 2018
jpb
added a commit
to jpb/js-yaml
that referenced
this issue
Oct 30, 2018
Any news on this feature? |
I'd appreciate this too! |
This was referenced Jan 22, 2020
Fixed by 7b256d7 in dev branch, gonna be released later. console.log(require('js-yaml').dump({ key: "this_is_a_key" }, { quotingType: '"', forceQuotes: true }))
// outputs:
// key: "this_is_a_key" |
This was referenced Mar 11, 2021
This was referenced Mar 16, 2021
# for free
to join this conversation on GitHub.
Already have an account?
# to comment
I would like to be able to take a json object like this :
and output a yml file like this :
I've tried several method but was only able to achieve either
or
note that in the latter this is not three quotes but a single quote followed by a double quote
Is there any way to do this with this module?
The text was updated successfully, but these errors were encountered: