Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The percent filter formats a number as a percentage. It takes the optional, decimals parameter, whose default value is 0.

For example:

{{ 0.4512 | percentage percent }} returns 45%

{{ 0.4512 | percentagepercent(2) }} returns 45.12%