mozilla / nunjucks

A powerful templating engine with inheritance, asynchronous control, and more (jinja2 inspired)
https://mozilla.github.io/nunjucks/
BSD 2-Clause "Simplified" License
8.48k stars 635 forks source link

Get a random number? #1386

Closed piskello closed 2 years ago

piskello commented 2 years ago

Hi, I need to get a random number within a JSON length, so I started following the example provided in the documentation {{ [1,2,3,4,5,6,7,9] | random }} ...but I always receive the same number at every page refresh... where am I wrong?