Open
Description
The map
parameter has no effect when the list of allowed
locales is provided and it only includes full locale tags. This is not clear from the documentation. It this behavior desired at all?
Example configuration:
expressLocale({
priority: ['query', 'map', 'default'],
allowed: ['en-CA', 'fr-CA'],
map: { en: 'en-CA', fr: 'fr-CA' },
})
With this configuration a request with query string ?locale=fr
will not have locale set to fr-CA
.
If this is indeed a desired behavior it would be nice to mention it in the documentation. Or is this a bug?
Metadata
Metadata
Assignees
Labels
No labels