title: Flask how to pass list of list to javascript
body: <p>I want to pass query results as a list to javascript</p>
  
  <p><strong>Python</strong></p>
  
  <pre><code>dataSet = []
  result = db.engine.execute("SELECT * FROM ....")
  for g in result :
      dataSet.append(g)
  return render_template('webpage.html', title=_('title'), dataSet=dataSet)
  </code></pre>
  
  <p><strong>HTML</strong></p>
  
  <pre><code>&lt;script type="text/javascript"&gt;
      var dataSets = {{ dataSet | safe }};
  &lt;/script&gt;
  </code></pre>
  
  <p>this injects list like <code>[(item1), (item2)]</code> but i need it to be like <code>[[item1], [item2]]</code> to pass javascript and continue there</p>
  
  <p>can't figure it out. Tried numpy arrays but it won't insert "," comma between elements.</p>