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 🙏

© 2026 – Pkg Stats / Ryan Hefner

indian-l10n

v1.0.2

Published

Indian language localization package compatible with Scratch-style translation keys. Supports Hindi, Tamil, Telugu, Bengali, and more.

Readme

indian-l10n 🇮🇳

Indian language localization package compatible with Scratch-style translation keys. Provides ready-to-use translations for Hindi, Tamil, Telugu, and Bengali — designed for block-based programming environments.

Installation

npm install indian-l10n

Quick Start

const { getLanguage, supportedLocales } = require('indian-l10n');

// Get Hindi translations
const hi = getLanguage('hi');
console.log(hi['gui.menuBar.file']); // "फ़ाइल"
console.log(hi['blocks.category.motion']); // "गति"

// Falls back to English if locale not found
const fallback = getLanguage('fr');
console.log(fallback['gui.menuBar.file']); // "File"

API

getLanguage(code)

Returns a flat translation object for the given locale code. Falls back to English (en) if the code is not found.

const ta = getLanguage('ta');
console.log(ta['gui.saveNow']); // "இப்போது சேமி"

languages

Direct access to all language objects, keyed by locale code.

const { languages } = require('indian-l10n');
console.log(languages.te['gui.controls.go']); // "మొదలుపెట్టు"

supportedLocales

Metadata for each supported locale including code, name, and nativeName.

const { supportedLocales } = require('indian-l10n');
console.log(supportedLocales.bn.nativeName); // "বাংলা"

isRtl(code)

Returns true if the locale is right-to-left. (No Indian languages are RTL, but included for Scratch compatibility.)

getLanguageNativeName(code)

Returns the native-script name of a language. Returns null for unsupported codes.

const { getLanguageNativeName } = require('indian-l10n');
console.log(getLanguageNativeName('hi')); // "हिन्दी"

getLocaleList()

Returns an array of all supported locale codes.

const { getLocaleList } = require('indian-l10n');
console.log(getLocaleList()); // ['en', 'hi', 'ta', 'te', 'bn']

isLocaleSupported(code)

Returns true if the given locale code is supported.

Supported Languages

| Code | Language | Native Name | |------|----------|-------------| | en | English | English | | hi | Hindi | हिन्दी | | ta | Tamil | தமிழ் | | te | Telugu | తెలుగు | | bn | Bengali | বাংলা |

Translation Key Format

Translation keys follow Scratch's dot-separated convention:

| Category | Example Key | Description | |----------|-------------|-------------| | GUI Menu | gui.menuBar.file | Menu bar items | | GUI Actions | gui.saveNow | Action buttons | | Modals | gui.modal.ok | Dialog buttons | | Alerts | gui.alert.saving | Status messages | | Sprite Tabs | gui.spriteTabs.code | Tab labels | | Stage | gui.stageHeader.fullscreen | Stage controls | | Blocks | blocks.category.motion | Block categories | | Paint Editor | paint.paintEditor.undo | Paint tools | | Color Picker | paint.colorPicker.color | Color controls |

Adding a New Language

  1. Create a new JSON file in src/languages/ (e.g., mr.json for Marathi)
  2. Copy the keys from en.json and translate the values
  3. Register the language in src/index.js:
    • Import the JSON file
    • Add it to the languages object
    • Add metadata to supportedLocales
  4. Update index.d.ts with the new locale type

Contributing

Contributions are welcome! To add or improve translations:

  1. Fork this repository
  2. Create a new branch: git checkout -b add/language-code
  3. Add or edit the language JSON file in src/languages/
  4. Ensure all keys from en.json are present and translated
  5. Run tests: npm test
  6. Submit a pull request

Translation Guidelines

  • Keep translations natural and culturally appropriate
  • Maintain the same key structure as en.json
  • Use Unicode characters — no transliteration
  • Technical terms (e.g., "sprite") may be transliterated when no standard term exists

License

MIT