System.Text.Json(JsonDocument/JsonElement) support in LINQPad 6?

As the blog saids, the new System.Text.Json is faster and efficient than Newtonsoft.Json, especially in UTF-8 area.
Do we have any plan to support System.Text.Json?

var doc = JsonDocument.Parse(utf8ByteContent); // just like JObject/JToken
doc.Dump();

Comments

  • What would you expect LINQPad to output?

    JsonDocument is not like Newtsonsoft.Json - there are no properties for LINQPad to walk.

    To use it, you write code like this:
    doc.RootElement.GetProperty ("runtimeTarget").GetProperty ("name").GetString();
    
  • Well, looks like this is not possible for JsonDocument.😂
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!