Using JavaScript loopsCreating additional routes

app.locals(.appdata) non disponible dans routes/

//routes/index.js
(...)
var appdata = require('path/to/data.json');
(html)
<% if (some.data.length > 0 { %>
  <% for (i=0; i<some.data.length; i++) { %>
    <li>some.data[i]
  <% } %>
<% } %>