number_format
Add thousands separators and optional decimal places.
Syntax
{{ value | number_format }}{{ value | number_format:2 }}Example
Basic usage
1{2 "amount": 1234567.893}1{{ amount | number_format:2 }}11,234,567.89Behavior
- The optional parameter sets the number of decimal places.