@narando/express-read-language-from-user

0.36.0 • Public • Published

@narando/express-read-language-from-user

A middleware to set the language wich will be used by i18next.

Getting Started

You need to have nodejs, npm, express and 18next installed.

$ npm install @narando/express-read-language-from-user

Usage

The middleware will use languages from the user object at req and has the i18next language as fallback:

import changeUILanguage from "@narando/express-read-language-from-user";

// add middleware to express
app.router(changeUILanguage());

You should use this in combination with @narando/express-i18n-middleware and @narando/preferred-ui-language

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.36.0
    0
    • latest

Version History

Package Sidebar

Install

npm i @narando/express-read-language-from-user

Weekly Downloads

0

Version

0.36.0

License

UNLICENSED

Unpacked Size

6.35 kB

Total Files

5

Last publish

Collaborators

  • narandosystem
  • marcmogdanz
  • apricote
  • brandolpho