-
-
Notifications
You must be signed in to change notification settings - Fork 381
Open
Labels
Status: ProposalRequest for commentsRequest for comments
Description
Clear and concise description of the problem
In order to ease usage of Intl.ListFormat with Vue i18n, I suggest to add a method $l which waits for 2 parameters where the second is optional.
This could avoid to boilerplate code thus passing the locale in the native method each time
Suggested solution
The method will use the native method Intl.ListFormat to display the array of string elements and join with the proper localized separator (, | and | or) for english.
So the method signature would be following:
function $l(list: string[], options?: Pick<ListFormatOptions, 'type' | 'style'> = { type: 'conjunction', style: 'long' }): stringAlternative
No response
Additional context
No response
Validations
- Read the Contributing Guidelines
- Read the Documentation
- Check that there isn't already an issue that request the same feature to avoid creating a duplicate.
Metadata
Metadata
Assignees
Labels
Status: ProposalRequest for commentsRequest for comments