gwlc
v1.0.2
Published
Provides data about languages spoken around the world, including their codes and names.
Downloads
12
Maintainers
Readme
𝚐𝚠𝚕𝚌 Global World Language Codes
Provides data about languages spoken around the world, including their codes and names.
Installation
$ npm install --save gwlc
or you can use yarn
$ yarn add gwlc
To use gwlc
, simply require it in your Node.js project:
const gwlc = require('gwlc');
Use the methods all
, find
, or filter
to get the language you need.
// Get all languages
gwlc.all();
// Find a specific language by name or code
gwlc.find('English'); // Finds by name
gwlc.find('en'); // Finds by code
// Filter languages by a search term (case-insensitive)
gwlc.filter('span'); // Matches languages like 'Spanish'
gwlc.filter('en'); // Matches languages with 'en' in their name or code
Contributing
- Fork it!
- Create your feature branch:
git checkout -b my-new-feature
- Commit your changes:
git commit -am 'Add some feature'
- Push to the branch:
git push origin my-new-feature
- Submit a pull request :D