title: Convert string to typed array in Javascript
body: <p>I have a string that should be parsed to JSON and than should be converted to a Float32Array.
  The string looks like this: </p>
  
  <pre><code>{"vertices":"[-1.0, -1.0, -1.0, -1.0, -1.0, 0.0, 1.0, -1.0, 0.0]"}
  </code></pre>
  
  <p>The Array should be assigned to a variable, e.g.:</p>
  
  <pre><code>mesh.vertices = new Float32Array([-1.0, -1.0, -1.0, -1.0, -1.0, 0.0, 1.0, -1.0, 0.0]);
  </code></pre>
  
  <p>How can I convert the string so that the array consists of float numbers?
  For security reasons, I don´t want to use eval().</p>