Showing posts with label doubel quotes. Show all posts
Showing posts with label doubel quotes. Show all posts

Saturday, 15 October 2022

No More " Escaping Needed with C# 11

Writing json body in C# code as a string variable value to pass on to a method or service, is something you may hate as you need to escape every " that you use in your json specification, even though you could use @ (verbatim string literals) to write multi-line strings.  With new Raw String Literals in c# 11, we can write " as content of the strings wihtout having to escape each instance. Let's explore bit about escaping double qutes with Raw String Literals.

Popular Posts