goog.labs.i18n.ListFormat |
Formats an array of strings into a string.
It is a user facing, locale-aware list (i.e. 'red, green, and blue').
|
code » | |
Replaces the {0} and {1} placeholders in a pattern with the first and
the second parameter respectively, and returns the result.
It is a helper function for goog.labs.i18n.ListFormat.format.
|
code » |
![]()
String for the end of a list items, containing {0} for the first part
of the list, and {1} for the last item.
This is how start/middle/end come together:
start = '{0}, {1}' middle = '{0}, {1}', end = '{0}, and {1}'
will result in the typical English list: 'one, two, three, and four'
There are languages where the patterns are more complex than
'{1} someText {1}' and the start pattern is different than the middle one.
|
Code » | |
![]()
String for the start of a list items, containing {0} for the first part
of the list, and {1} for the rest of the list.
|
Code » | |
![]()
String for the start of a list items, containing {0} for the first,
and {1} for the rest.
|
Code » | |
![]()
String for lists of exactly two items, containing {0} for the first,
and {1} for the second.
For instance '{0} and {1}' will give 'black and white'.
|
Code » |