Keep native types after conversion to json #1051
mieliespoor
started this conversation in
General
Replies: 1 comment
-
Try to use Example Code var deserializer = new DeserializerBuilder().WithAttemptingUnquotedStringTypeDeserialization().Build();
var model= deserializer.Deserialize(yaml);
var results = JsonSerializer.Serialize(model, new JsonSerializerOptions { WriteIndented = true }); |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I have been using this library to convert yaml to json, but it appears that integers and boolean values are converted to string in the resulting json.
source:
result:
expected:
What settings should be passed so that valid json would be produced? The issue we see is that converted json does not pass schema validations which causes failures.
Beta Was this translation helpful? Give feedback.
All reactions