title: Extract JSON from text
body: <p>An AJAX call is returning a response text that includes a JSON string. I need to:</p>
  
  <ol>
  <li>extract the JSON string</li>
  <li>modify it</li>
  <li>then reinsert it to update the original string</li>
  </ol>
  
  <p>I am not too worried about steps 2 and 3, but I can't figure out how to do step 1. I was thinking about using a regular expression, but I don't know how as my JSON might have multiple levels with nested objects or arrays.</p>