Most performant way to check if a string is a well formatted JSON #70371
Unanswered
MithrilMan
asked this question in
Q&A
Replies: 1 comment 5 replies
-
Try |
Beta Was this translation helpful? Give feedback.
5 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 know there are a couple of solutions to check if a string is a well formed JSON, like wrapping a
JsonDocument.Parse
orJsonSerializer.Deserialize
call in a try-catch but I'm looking for a performant way to do that.Does .Net6 have some performant API to do that (low allocation, no try/catch)?
Beta Was this translation helpful? Give feedback.
All reactions