I\'m building a website where people can associate a language information to content.
The website uses Javascript heavily and the language information associated to
Another solution is to use iso-639-1 package.
Installation:
npm install iso-639-1
Usage in Node.js:
const ISO6391 = require('iso-639-1')
console.log(ISO6391.getAllCodes()) // ['aa', 'ab', ...]
console.log(ISO6391.getName('cv')) // 'Chuvash'
console.log(ISO6391.getNativeName('cv')) // 'чӑваш чӗлхи'
Usage in browsers: