Proxy filter for calling underscore string function
string
Type: String
String to filter
fn
Type: String
Underscore function to call
params
Type: Parameters
Extra parameters to pass to Underscore string
Type: String
Formatted string
{{ "this_Is_aTestFor_Underscore_string" | underscoreString: "humanize" }}
{{ "Truncating: lorem ipsum dolor sit amet, consectetur adipiscing elit." | underscoreString: "truncate": 42 }}
{{ "Pruning: lorem ipsum dolor sit amet, consectetur adipiscing elit." | underscoreString: "prune": 42: "... (show more)" }}
<p>{{ "this_Is_aTestFor_Underscore_string" | underscoreString: "humanize" }}</p>
Pluralizes the given string. It's a simple proxy to the pluralize function on util.
string
Type: String
Noun to pluralize
count
Type: Integer
The numer of objects
includeCount
Type: Boolean
To include the number in formatted string
Type: String
Formatted plural
{{"person" | pluralize:1500}}
Takes in a unix timestamp and turns it into a human-readable relative time string, like "5
minutes ago" or "just now".
time
Type: Unix timestamp
The time to format
Type: String
Formatted string
{{ fiveMinAgo | timestamp }}
List filter. Use for converting arrays into a string
list
Type: Array
Array of items
separator
Type: String
String to separate each element of the array (default ,)
Type: String
Formatted string
{{ ["item1", "item2", "item3", "item4"] | list }}
{{ ["item1", "item2", "item3", "item4"] | list }}