alp-browser-language
v5.0.5
Published
language context in alp framework
Downloads
89
Readme
Config file
common:
availableLanguages: [en, fr]
With Ibex
import Ibex from 'ibex';
import config from 'alp-browser-config';
import language from 'alp-browser-language';
const app = new Ibex();
config('/config')(app);
language(app);
context
language: string
First accepted language in the header / in navigator.languages
contained in availableLanguages
, or the first language in availableLanguages
.
firstAcceptedLanguage: string
The first accepted language in the header / in navigator.languages
regardless of availableLanguages
. Can be a locale. Usefull for date/time/...