npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

iso-639-2

v3.0.2

Published

ISO-639-2 codes in an accessible format

Downloads

12,619

Readme

iso-639-2

Build Coverage Downloads Size

Info on ISO 639-2.

Contents

What is this?

This package contains info on ISO 639-2. ISO 639-2 is the alpha-3 code in Codes for the representation of names of languages – Part 2.

When should I use this?

You can use this package any time you have to deal with languages or ISO 639-2 in particular. But ISO 639-3 might be better.

Install

This package is ESM only. In Node.js (version 12.20+, 14.14+, or 16.0+), install with npm:

npm install iso-639-2

In Deno with esm.sh:

import {iso6392} from 'https://esm.sh/iso-639-2@3'

In browsers with esm.sh:

<script type="module">
  import {iso6392} from 'https://esm.sh/iso-639-2@3?bundle'
</script>

Use

import {iso6392} from 'iso-639-2'

iso6392.slice(120, 150)

Yields:

[
  {name: 'Egyptian (Ancient)', iso6392B: 'egy'},
  {name: 'Ekajuk', iso6392B: 'eka'},
  {name: 'Elamite', iso6392B: 'elx'},
  {name: 'English', iso6392B: 'eng', iso6391: 'en'},
  {name: 'English, Middle (1100-1500)', iso6392B: 'enm'},
  {name: 'Esperanto', iso6392B: 'epo', iso6391: 'eo'},
  {name: 'Estonian', iso6392B: 'est', iso6391: 'et'},
  {name: 'Ewe', iso6392B: 'ewe', iso6391: 'ee'},
  {name: 'Ewondo', iso6392B: 'ewo'},
  {name: 'Fang', iso6392B: 'fan'},
  {name: 'Faroese', iso6392B: 'fao', iso6391: 'fo'},
  {name: 'Fanti', iso6392B: 'fat'},
  {name: 'Fijian', iso6392B: 'fij', iso6391: 'fj'},
  {name: 'Filipino; Pilipino', iso6392B: 'fil'},
  {name: 'Finnish', iso6392B: 'fin', iso6391: 'fi'},
  {name: 'Finno-Ugrian languages', iso6392B: 'fiu'},
  {name: 'Fon', iso6392B: 'fon'},
  {name: 'French', iso6392B: 'fre', iso6392T: 'fra', iso6391: 'fr'},
  {name: 'French, Middle (ca.1400-1600)', iso6392B: 'frm'},
  {name: 'French, Old (842-ca.1400)', iso6392B: 'fro'},
  {name: 'Northern Frisian', iso6392B: 'frr'},
  {name: 'Eastern Frisian', iso6392B: 'frs'},
  {name: 'Western Frisian', iso6392B: 'fry', iso6391: 'fy'},
  {name: 'Fulah', iso6392B: 'ful', iso6391: 'ff'},
  {name: 'Friulian', iso6392B: 'fur'},
  {name: 'Ga', iso6392B: 'gaa'},
  {name: 'Gayo', iso6392B: 'gay'},
  {name: 'Gbaya', iso6392B: 'gba'},
  {name: 'Germanic languages', iso6392B: 'gem'},
  {name: 'Georgian', iso6392B: 'geo', iso6392T: 'kat', iso6391: 'ka'}
]

API

This package exports the following identifiers: iso6392, iso6392BTo1, iso6392BTo2T, iso6392TTo1, and iso6392TTo2B. There is no default export.

iso6392

List of languages (Array<Language>).

Language

  • name (string) — language name
  • iso6392B (string) — bibliographic code
  • iso6392T (string?) — terminologic code, missing when both 639-2 codes are the same (21 languages have different bibliographic and terminologic codes)
  • iso6391 (string?) — ISO 639-1 code

iso6392BTo1

ISO 639-2 Bibliographic (dut) to ISO 639-1 (nl) (Record<string, string>).

iso6392BTo2T

ISO 639-2 Bibliographic (dut) to ISO 639-2 Terminologic (nld) (Record<string, string>) Missing when the bibliographic and terminologic codes are the same.

iso6392TTo1

ISO 639-2 Terminologic (nld) to ISO 639-1 (nl) (Record<string, string>). Not all language in 639-2 were available in 639-1.

iso6392TTo2B

ISO 639-2 Terminologic (nld) to ISO 639-2 Bibliographic (dut) (Record<string, string>). Missing when the bibliographic and terminologic codes are the same.

Types

This package is fully typed with TypeScript. An additional Language type is exported that models its respective interface.

Data

The data is crawled from www.loc.gov.

Compatibility

This package is at least compatible with all maintained versions of Node.js. As of now, that is Node.js 12.20+, 14.14+, and 16.0+. It also works in Deno and modern browsers.

Security

This package is safe.

Related

Contribute

Yes please! See How to Contribute to Open Source.

License

MIT © Titus Wormer