Answers for "how to transform object in string with scaped"

0

how to transform object in string with scaped

var data = { data: "Hello World" };

JSON.stringify(JSON.stringify(data));

> '"{\"data\":\"Hello World\"}"'
Posted by: Guest on October-13-2021

Code answers related to "how to transform object in string with scaped"

Code answers related to "Javascript"

Browse Popular Code Answers by Language