github mozilla/nunjucks v2.4.0

latest releases: v3.2.4, v3.2.3, v3.2.2...
8 years ago

Lots of great bugfixes and small new features in this release! Many thanks to all the contributors.

  • Allow retrieving boolean-false as a global. Thanks Marius Büscher. Merge of
    #694.
  • Don't automatically convert any for-loop that has an include statement into
    an async loop. Reverts
    7d4716f4fd, re-opens
    #372, fixes
    #527. Thanks Tom Delmas for
    the report.
  • Switch from Optimist to Yargs for argument-parsing. Thanks Bogdan
    Chadkin. Merge of #672.
  • Prevent includes from writing to their including scope. Merge of
    #667 (only partially
    backported to 2.x; macro var visibility not backported).
  • Fix handling of dev environment option, to get full tracebacks on errors
    (including nunjucks internals). Thanks Tobias Petry and Chandrasekhar Ambula
    V for the report, Aleksandr Motsjonov for draft patch.
  • Support using in operator to search in both arrays and objects,
    and it will throw an error for other data types.
    Fix #659.
    Thanks Alex Mayfield for report and test, Ouyang Yadong for fix.
    Merge of #661.
  • Add support for {% set %} block assignments as in jinja2. Thanks Daniele
    Rapagnani. Merge of #656
  • Fix {% set %} scoping within macros.
    Fixes #577 and
    the macro portion of #561.
    Thanks Ouyang Yadong. Merge of #653.
  • Add support for named endblock (e.g. {% endblock foo %}). Thanks
    ricordisamoa. Merge of #641.
  • Fix range global with zero as stop-value. Thanks Thomas Hunkapiller. Merge
    of #638.
  • Fix a bug in urlize that collapsed whitespace. Thanks Paulo Bu. Merge of
    #637.
  • Add sum filter. Thanks Pablo Matías Lazo. Merge of
    #629.
  • Don't suppress errors inside {% if %} tags. Thanks Artemy Tregubenko for
    report and test, Ouyang Yadong for fix. Merge of
    #634.
  • Allow whitespace control on comment blocks, too. Thanks Ouyang Yadong. Merge
    of #632.
  • Fix whitespace control around nested tags/variables/comments. Thanks Ouyang
    Yadong. Merge of #631.

Don't miss a new nunjucks release

NewReleases is sending notifications on new releases.