Twig Engine default


Twig.js

Nodefony use twig.js : JS port of the Twig templating language of symfony framework See more ( twig.sensiolabs.org ).

TWIG.js Differences / Implementation Notes Implementation Notes

Built-in Tags:

  • autoescape:
  • block: Supported
  • do:
  • extends: Supported
  • filter: Supported
  • flush: N/A
  • for: Supported
  • from: Supported
  • if: Supported
  • import: Supported
  • include: Supported
  • macro: Supported
  • raw:
  • sandbox:
  • set: Supported
  • spaceless: Supported
  • use: Supported

Built-in Filters:

  • abs: Supported
  • batch: Supported
  • capitalize: Supported
  • convert_encoding: N/A
  • date: Supported
  • date_modify: Supported
  • default: Supported
  • escape: Supported
  • first: Supported
  • format: Supported
  • join: Supported
  • json_encode: Supported
  • keys: Supported
  • last: Supported
  • length: Supported
  • lower: Supported
  • merge: Supported
  • nl2br: Supported
  • number_format: Supported
  • merge: Supported
  • raw:
  • replace: Supported
  • reverse: Supported
  • round: Supported
  • slice: Supported
  • sort: Supported
  • split: Supported
  • striptags: Supported
  • title: Supported
  • trim: Supported
  • upper: Supported
  • url_encode: Supported

Built-in Functions:

  • attribute: Supported
  • block: Supported
  • constant:
  • cycle: Supported
  • date: Supported
  • dump: Supported
  • include:
  • max: Supported
  • min: Supported
  • parent: Supported
  • random: Supported
  • range: Supported
  • source: Supported

Built-in Tests:

  • constant:
  • defined: Supported
  • divisibleby: Supported
  • empty: Supported
  • even: Supported
  • iterable: Open Pull Request #165
  • null / none: Supported
  • odd: Supported
  • sameas: Supported

Built-in Operators:

  • in: Supported
  • is: Supported
  • Math (+, -, /, %, *, **): Supported
  • Logic (and, or, not, ()): Supported
  • Comparisons (==, !=, <, >, >=, <=, ===): Supported
  • Others (.., |, ~, ., [], ?:): Supported
  • Null-coalescing (??): Issue #319 open