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

tekivex-india-admin

v0.1.0-alpha.1

Published

Pluggable DivisionsLoader for tekivex-ui's TkxAddressInput, bundling a snapshot of the Government of India's Local Government Directory: states / UTs, districts, and sub-districts with region-correct labels (Taluka / Tehsil / Mandal / Block / Circle). Sou

Readme

tekivex-india-admin

Pluggable DivisionsLoader for tekivex-ui's TkxAddressInput, bundling a snapshot of the Government of India's Local Government Directory (LGD) — every state / UT, every district, every sub-district — with region-correct labels (Taluka / Tehsil / Mandal / Block / Circle / Sub-division) so your forms speak the same admin language as the locality they're filed in.

npm install tekivex-india-admin

Status

v0.1.0-alpha.1 — API stable, exemplar dataset only. Full LGD snapshot in v0.1.0. See coverage below.

Quick start

import { TkxAddressInput } from 'tekivex-ui';
import { lgdSnapshot } from 'tekivex-india-admin';

// Memoize at module level — identity stable across renders:
const divisions = lgdSnapshot();

function ShippingForm() {
  const [addr, setAddr] = useState({});
  return (
    <TkxAddressInput
      value={addr}
      onChange={setAddr}
      divisionsSource={divisions}
    />
  );
}

That's the whole integration. The component now renders a cascading row of four dropdowns above the PIN field — Country → State / UT → District → (Taluka / Tehsil / Mandal / Block / …, picked per-state) — and writes both display names and stable ISO 3166-2 / LGD codes into the value object.

What you get

import { lgdSnapshot, lgdSnapshotMeta, type DivisionsLoader } from 'tekivex-india-admin';

lgdSnapshot(options?): DivisionsLoader

Build a loader backed by the bundled JSON snapshot. Options:

| Field | Type | Default | Description | |---|---|---|---| | onlyStates | readonly string[] | all 36 | ISO 3166-2 codes to restrict to. Useful when your product only operates in certain states. |

lgdSnapshotMeta

{
  snapshotDate: '2026-05-30',
  provider: 'Ministry of Panchayati Raj, Government of India',
  source: 'Local Government Directory (LGD)',
  sourceUrl: 'https://lgdirectory.gov.in/',
  license: 'GODL-India v1.0',
}

Display the snapshotDate somewhere in your product's "About" / settings page so users know how fresh the boundary data is.

Regional sub-district labels

The right name for the sub-district level varies by state. The loader's subDistrictLabel(countryCode, stateCode) returns the correct label per LGD/state-government convention:

| States | Label | |---|---| | Maharashtra, Gujarat, Goa | Taluka | | Karnataka, Kerala, Tamil Nadu | Taluk | | Andhra Pradesh, Telangana | Mandal | | West Bengal, Jharkhand, Odisha | Block | | UP, Bihar, Rajasthan, MP, Haryana, Punjab, Uttarakhand, HP, J&K, Ladakh, Chhattisgarh | Tehsil | | Assam, Arunachal Pradesh | Circle | | Mizoram, Nagaland, Tripura | RD Block | | Manipur, Sikkim | Sub-division | | Meghalaya | C&RD Block |

TkxAddressInput calls subDistrictLabel automatically and re-renders the 4th dropdown's label whenever the selected state changes.

Custom data sources

DivisionsLoader is just an interface. You can plug in any source:

  • A REST endpoint backed by your own database
  • A lazy-imported chunk of a larger dataset
  • A subset of the LGD snapshot mixed with your own internal codes
  • A non-India loader (Indonesia, Brazil, Pakistan, …)

Any object that satisfies the DivisionsLoader shape is a valid value for TkxAddressInput's divisionsSource prop.

Coverage

v0.1.0-alpha.1 ships:

  • ✅ States / UTs — complete (all 36)
  • ⚠️ Districts — exemplar set only (~50 districts across 10 major states: MH, KA, TN, DL, WB, AP, UP, GJ, KL, RJ). Sufficient to demo the cascade UI end-to-end. Other state codes will return an empty districts() array.
  • ⚠️ Sub-districts — exemplar set only (one district per major state). Other district codes will return an empty subDistricts() array.

Full LGD coverage will be ingested for v0.1.0 (non-alpha). The data pipeline is being built; see tracking issue tagged india-admin-data.

License & attribution

This package's code is MIT-style; the data is published under the Government Open Data License — India (GODL-India) v1.0. The two are bundled together because the package's value IS the data.

Attribution for downstream consumers

If you ship a product built on this package, paste this into your app's NOTICES / About / Credits page:

Indian administrative-division data sourced from the Local Government Directory (https://lgdirectory.gov.in/), Ministry of Panchayati Raj, Government of India, under the Government Open Data License — India (GODL-India v1.0). Snapshot dated 2026-05-30. Bundled via tekivex-india-admin.

See NOTICE.md for the full attribution and exclusions.

What this package is NOT

  • Not a legal source of truth. Admin boundaries change (J&K 2019, district splits, UT reorganisations). Re-snapshot for legally significant decisions.
  • Not a GoI / state-government logo or emblem ship. GODL-India excludes crests and symbols; this package strictly does too.
  • Not a village-level directory. LGD has ~640,000 villages; bundling them into a React-app dependency is a non-goal. Use the LGD REST API or your own backend for that.
  • Not certified or endorsed by the Ministry of Panchayati Raj or any Indian government department. This is an independent, GODL-compliant redistribution.

Contributing

If you'd like to help complete the snapshot coverage, see the contributing guide and the india-admin-data tag on the issue tracker.