|<- [[Using JavaScript loops]]|[[Creating 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[i] <% } %> <% } %>
//routes/index.js (...) var appdata = require('path/to/data.json');
(html) <% if (some.data.length > 0 { %> <% for (i=0; i some.data[i] <% } %> <% } %>