title: Pass python list from context to JS function
body: <p>I have a view that renders a dictionary of data for each country like below:</p>
  <pre><code>def InvoicingDashboardView(request):
      # For reference - &quot;c&quot; is the context dictionary, and it's already initialized by this point
  
      for client in Client.objects.all():
          fte = frame.fte(c['start_date'], c['end_date'], time = 'external', client = client.id)
  
          if fte &gt; 0:
              c['countrys'][client] = {
                  'name': client.name,
                  'fte': fte,
                  'var_fte': fte - frame.fte(c['var_start_date'], c['var_end_date'], client = client.id),
                  'daily_ftes': [frame.fte(day, day) for day in c['label_days']],
              }
      
  
      return render(request, 'dashboards/invoicing.html', context = c)
  </code></pre>
  <p>As you can see, for example, if i call <code>{{countrys.client.fte}}</code> i'll get the fte for that client.</p>
  <p>Everything good till now, but i'll need the <code>daily_ftes</code> for a JS function, like below:</p>
  <pre><code>&lt;div class=&quot;dash_countrys_ftes&quot;&gt;
      {% for country, items in countrys.items %}
          &lt;div class=&quot;dash_country_block&quot;&gt;
          {% with name=items.name fte=items.fte variation=items.var_fte flag=country.flag.url %}
              {% include 'dashboards/charts/country_block.html' %}
          {% endwith %}
          &lt;/div&gt;
          &lt;script&gt;
              countryFteVariation(&quot;{{items.daily_ftes|escapejs}}&quot;) // HERE
          &lt;/script&gt;
      {% endfor %}
  &lt;/div&gt;
  </code></pre>
  <p>The problem is that <code>daily_ftes</code> is a python list.</p>
  <p>What can i do here in order to javascript read it as list instead of a string?</p>