jQuery JSON to String

Share this article

Simple JavaScript function to convert a JSON string into a comma seperated item quoted list for display.

Also see jsfiddle for JSON.stringify https://jsfiddle.net/ifandelse/6Yj5h/

//helper function to convert json to string
stripJsonToString: function(json)
    return JSON.stringify(json).replace(',', ', ').replace('[', '').replace(']', '');
//email@email.com, example@example.com, somebody@somewhere.com
Sam DeeringSam Deering
View Author

Sam Deering has 15+ years of programming and website development experience. He was a website consultant at Console, ABC News, Flight Centre, Sapient Nitro, and the QLD Government and runs a tech blog with over 1 million views per month. Currently, Sam is the Founder of Crypto News, Australia.

Share this article
Read Next
Get the freshest news and resources for developers, designers and digital creators in your inbox each week