{"_id":"@countrystatecity/translations","_rev":"5-efc9fcc8adca49ea5498b1263cdf1cb3","name":"@countrystatecity/translations","dist-tags":{"latest":"1.0.4"},"versions":{"1.0.0":{"name":"@countrystatecity/translations","version":"1.0.0","keywords":["country-state-city","translations","i18n","localization","country-names","multilingual","typescript","lazy-loading"],"author":{"name":"dr5hn"},"license":"ODbL-1.0","_id":"@countrystatecity/translations@1.0.0","maintainers":[{"name":"dr5hn","email":"gadadarshan@gmail.com"}],"homepage":"https://github.com/dr5hn/countrystatecity-translations#readme","bugs":{"url":"https://github.com/dr5hn/countrystatecity-translations/issues"},"dist":{"shasum":"d6f1b2b5ef56c9cb97d34ca129692329d506b062","tarball":"https://registry.npmjs.org/@countrystatecity/translations/-/translations-1.0.0.tgz","fileCount":9,"integrity":"sha512-m5V7m48C+0WXyJwNMqQ0kVQV5d2ZcDkYgRCqztCHnPcal9eHnx4t8LY3Zvm1ja1ZVIpiHB7NWZrDybjwrio25Q==","signatures":[{"sig":"MEQCIGBeZm/kPOEsv/E9Oz+0OvCq0xgNj3bY+W4A6EIIliPRAiBsHOsrw8H7fJNm9ZQdssgd1xe6zb7FzebrJMrUmyOySQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":185020},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./data/*":"./dist/data/*"},"gitHead":"7b421bdc860b2b9da594d4d8afd8f95d879a011c","scripts":{"dev":"tsup --watch","test":"vitest run","build":"tsup","typecheck":"tsc --noEmit","test:watch":"vitest","test:compat":"vitest run compatibility"},"_npmUser":{"name":"dr5hn","email":"gadadarshan@gmail.com"},"repository":{"url":"git+https://github.com/dr5hn/countrystatecity-translations.git","type":"git"},"_npmVersion":"10.8.2","description":"Country name translations in 19 languages — Arabic, German, French, Spanish, and more","directories":{},"_nodeVersion":"20.20.2","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.5.0","vitest":"^4.1.8","typescript":"^5.9.0","@types/node":"^20.19.0"},"_npmOperationalInternal":{"tmp":"tmp/translations_1.0.0_1780571548077_0.739266226457465","host":"s3://npm-registry-packages-npm-production"}},"1.0.1":{"name":"@countrystatecity/translations","version":"1.0.1","keywords":["country-state-city","translations","i18n","localization","country-names","multilingual","typescript","lazy-loading"],"author":{"name":"dr5hn"},"license":"ODbL-1.0","_id":"@countrystatecity/translations@1.0.1","maintainers":[{"name":"dr5hn","email":"gadadarshan@gmail.com"}],"homepage":"https://github.com/dr5hn/countrystatecity-translations#readme","bugs":{"url":"https://github.com/dr5hn/countrystatecity-translations/issues"},"dist":{"shasum":"af5873cc1ca7f9167fa268c4d35c3b1c2a1eb592","tarball":"https://registry.npmjs.org/@countrystatecity/translations/-/translations-1.0.1.tgz","fileCount":9,"integrity":"sha512-DEb5LGYLzxaYcCnCRG6iK9C/6HlWEM6aVlXGwtsolwkmAGSEZXjyhN+h7c/lDFY1BjOBcxvjAB2zViGhs1x/fQ==","signatures":[{"sig":"MEYCIQCGWA05INq/VHXin7sQSCYWf/w55Jeuma6l+NAtP2nYFQIhAOxr6TuOhW+LliW/IkUriltdX1RfYIjip/gWjTxrZ8vK","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":190954},"main":"./dist/index.cjs","type":"module","_from":"file:countrystatecity-translations-1.0.1.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./data/*":"./dist/data/*"},"scripts":{"dev":"tsup --watch","test":"vitest run","build":"tsup","typecheck":"tsc --noEmit","test:watch":"vitest","test:compat":"vitest run compatibility"},"_npmUser":{"name":"dr5hn","email":"gadadarshan@gmail.com"},"_resolved":"/tmp/a2aa22b5ada8ad353d701cf2ba8b9fa5/countrystatecity-translations-1.0.1.tgz","_integrity":"sha512-DEb5LGYLzxaYcCnCRG6iK9C/6HlWEM6aVlXGwtsolwkmAGSEZXjyhN+h7c/lDFY1BjOBcxvjAB2zViGhs1x/fQ==","repository":{"url":"git+https://github.com/dr5hn/countrystatecity-translations.git","type":"git"},"_npmVersion":"10.8.2","description":"Country name translations in 19 languages — Arabic, German, French, Spanish, and more","directories":{},"_nodeVersion":"20.20.2","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.5.0","vitest":"^4.1.8","typescript":"^5.9.0","@types/node":"^20.19.0"},"_npmOperationalInternal":{"tmp":"tmp/translations_1.0.1_1781168802059_0.4979383913970412","host":"s3://npm-registry-packages-npm-production"}},"1.0.2":{"name":"@countrystatecity/translations","version":"1.0.2","keywords":["country-state-city","translations","i18n","localization","country-names","multilingual","typescript","lazy-loading"],"author":{"name":"dr5hn"},"license":"ODbL-1.0","_id":"@countrystatecity/translations@1.0.2","maintainers":[{"name":"dr5hn","email":"gadadarshan@gmail.com"}],"homepage":"https://github.com/dr5hn/countrystatecity-npm/tree/main/packages/translations#readme","bugs":{"url":"https://github.com/dr5hn/countrystatecity-npm/issues"},"dist":{"shasum":"77c057a37c04914a1f7f4ea18dc35cb4897240f3","tarball":"https://registry.npmjs.org/@countrystatecity/translations/-/translations-1.0.2.tgz","fileCount":9,"integrity":"sha512-NO7FgqMwtYHW27mUXanIoiEtoZ27NJPIZVjBxKjLoiCR4uMODh9FzrvIYX748ljkL3Nus1M+oB1oXzh4RzftCg==","signatures":[{"sig":"MEYCIQCqQM3inLJyIJIBNeo4bU1RTdqONbskAjnmHu0b1SngowIhALo9g7EQ9QSg9BNcachpOpxFw5+6Z0OjxfIItI1irhO3","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":191010},"main":"./dist/index.cjs","type":"module","_from":"file:countrystatecity-translations-1.0.2.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./data/*":"./dist/data/*"},"scripts":{"dev":"tsup --watch","test":"vitest run","build":"tsup","typecheck":"tsc --noEmit","test:watch":"vitest","test:compat":"vitest run compatibility","generate-data":"node scripts/generate-data.cjs"},"_npmUser":{"name":"dr5hn","email":"gadadarshan@gmail.com"},"_resolved":"/tmp/227719d4d0ce2eec6529f116e7932a21/countrystatecity-translations-1.0.2.tgz","_integrity":"sha512-NO7FgqMwtYHW27mUXanIoiEtoZ27NJPIZVjBxKjLoiCR4uMODh9FzrvIYX748ljkL3Nus1M+oB1oXzh4RzftCg==","repository":{"url":"git+https://github.com/dr5hn/countrystatecity-npm.git","type":"git"},"_npmVersion":"10.8.2","description":"Country name translations in 19 languages — Arabic, German, French, Spanish, and more","directories":{},"_nodeVersion":"20.20.2","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.5.0","vitest":"^4.1.8","typescript":"^5.9.0","@types/node":"^20.19.0"},"_npmOperationalInternal":{"tmp":"tmp/translations_1.0.2_1781173094122_0.05001616312653323","host":"s3://npm-registry-packages-npm-production"}},"1.0.3":{"name":"@countrystatecity/translations","version":"1.0.3","keywords":["country-state-city","translations","i18n","localization","country-names","multilingual","typescript","lazy-loading"],"author":{"name":"dr5hn"},"license":"ODbL-1.0","_id":"@countrystatecity/translations@1.0.3","maintainers":[{"name":"dr5hn","email":"gadadarshan@gmail.com"}],"homepage":"https://github.com/dr5hn/countrystatecity-npm/tree/main/packages/translations#readme","bugs":{"url":"https://github.com/dr5hn/countrystatecity-npm/issues"},"dist":{"shasum":"01512b6da31aeb54e95ab3609b35b161fc83c1e7","tarball":"https://registry.npmjs.org/@countrystatecity/translations/-/translations-1.0.3.tgz","fileCount":9,"integrity":"sha512-PbGAIREeEhoP4Isopx6z12VqraPQZsQq74wfORmGCoxq0u4/0VYyFp5zACoYFi6/4c8lNL8Wvo/pmPvRdvmwGw==","signatures":[{"sig":"MEYCIQDbV2uuHUCyTRRV823fIq+0+rFmE+hNPqRfHJmC6EE5OAIhAOx7smNrKiZ0d3ISZYzRu8GjGs7ZEBBV1LBPnb6d3VWd","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":191190},"main":"./dist/index.cjs","type":"module","_from":"file:countrystatecity-translations-1.0.3.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./data/*":"./dist/data/*"},"scripts":{"dev":"tsup --watch","test":"vitest run","build":"tsup","typecheck":"tsc --noEmit","test:watch":"vitest","test:compat":"vitest run compatibility","generate-data":"node scripts/generate-data.cjs"},"_npmUser":{"name":"dr5hn","email":"gadadarshan@gmail.com"},"_resolved":"/tmp/9a06219d2b75b442ae602882f6082df5/countrystatecity-translations-1.0.3.tgz","_integrity":"sha512-PbGAIREeEhoP4Isopx6z12VqraPQZsQq74wfORmGCoxq0u4/0VYyFp5zACoYFi6/4c8lNL8Wvo/pmPvRdvmwGw==","repository":{"url":"git+https://github.com/dr5hn/countrystatecity-npm.git","type":"git"},"_npmVersion":"10.8.2","description":"Country name translations in 19 languages — Arabic, German, French, Spanish, and more","directories":{},"_nodeVersion":"20.20.2","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.5.0","vitest":"^4.1.8","typescript":"^5.9.0","@types/node":"^20.19.0"},"_npmOperationalInternal":{"tmp":"tmp/translations_1.0.3_1786169494982_0.08073504719673652","host":"s3://npm-registry-packages-npm-production"}},"1.0.4":{"name":"@countrystatecity/translations","version":"1.0.4","description":"Country name translations in 19 languages — Arabic, German, French, Spanish, and more","keywords":["country-state-city","translations","i18n","localization","country-names","multilingual","typescript","lazy-loading"],"author":{"name":"dr5hn"},"license":"ODbL-1.0","repository":{"type":"git","url":"git+https://github.com/dr5hn/countrystatecity-npm.git"},"homepage":"https://github.com/dr5hn/countrystatecity-npm/tree/main/packages/translations#readme","bugs":{"url":"https://github.com/dr5hn/countrystatecity-npm/issues"},"type":"module","main":"./dist/index.cjs","module":"./dist/index.js","types":"./dist/index.d.ts","exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./data/*":"./dist/data/*"},"devDependencies":{"@types/node":"^20.19.0","tsup":"^8.5.0","typescript":"^5.9.0","vitest":"^4.1.8"},"publishConfig":{"access":"public"},"scripts":{"build":"tsup","dev":"tsup --watch","test":"vitest run","test:watch":"vitest","test:compat":"vitest run compatibility","typecheck":"tsc --noEmit","generate-data":"node scripts/generate-data.cjs"},"_id":"@countrystatecity/translations@1.0.4","_integrity":"sha512-0K20LuI12l1upoR4GNESGmu+Tq8eyf3YXwrNcsGyKOTqV9uzjUuGT4ykxO2HYmvJTunhgUg41g/B8c0sEXC/HA==","_resolved":"/tmp/977144e6a3d41f8909692596c9cf93fc/countrystatecity-translations-1.0.4.tgz","_from":"file:countrystatecity-translations-1.0.4.tgz","_nodeVersion":"20.20.2","_npmVersion":"10.8.2","dist":{"integrity":"sha512-0K20LuI12l1upoR4GNESGmu+Tq8eyf3YXwrNcsGyKOTqV9uzjUuGT4ykxO2HYmvJTunhgUg41g/B8c0sEXC/HA==","shasum":"9860fdff7599e4b5b01a2c8f8e7d37c2cb21f2a2","tarball":"https://registry.npmjs.org/@countrystatecity/translations/-/translations-1.0.4.tgz","fileCount":9,"unpackedSize":191190,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQDATXg5pUXEoDxw3NXEjcGp9pGJAv2eBg3b1+ZFLVc2wgIgTi1fL+CWcbSM7aNKMza5fZIY2PwWylEqW1oUpvApLjY="}]},"_npmUser":{"name":"dr5hn","email":"gadadarshan@gmail.com"},"directories":{},"maintainers":[{"name":"dr5hn","email":"gadadarshan@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/translations_1.0.4_1786188778769_0.15401983814838283"},"_hasShrinkwrap":false}},"time":{"created":"2026-06-04T11:12:27.869Z","modified":"2026-08-08T11:32:59.076Z","1.0.0":"2026-06-04T11:12:28.247Z","1.0.1":"2026-06-11T09:06:42.225Z","1.0.2":"2026-06-11T10:18:14.284Z","1.0.3":"2026-08-08T06:11:35.124Z","1.0.4":"2026-08-08T11:32:58.902Z"},"bugs":{"url":"https://github.com/dr5hn/countrystatecity-npm/issues"},"author":{"name":"dr5hn"},"license":"ODbL-1.0","homepage":"https://github.com/dr5hn/countrystatecity-npm/tree/main/packages/translations#readme","keywords":["country-state-city","translations","i18n","localization","country-names","multilingual","typescript","lazy-loading"],"repository":{"type":"git","url":"git+https://github.com/dr5hn/countrystatecity-npm.git"},"description":"Country name translations in 19 languages — Arabic, German, French, Spanish, and more","maintainers":[{"name":"dr5hn","email":"gadadarshan@gmail.com"}],"readme":"# @countrystatecity/translations\n\n[![npm](https://img.shields.io/npm/v/@countrystatecity/translations)](https://www.npmjs.com/package/@countrystatecity/translations)\n[![CI](https://github.com/dr5hn/countrystatecity-npm/workflows/Pipeline/badge.svg)](https://github.com/dr5hn/countrystatecity-npm/actions/workflows/ci.yml)\n[![npm downloads](https://img.shields.io/npm/dm/@countrystatecity/translations?label=translations)](https://www.npmjs.com/package/@countrystatecity/translations)\n[![npm downloads](https://img.shields.io/npm/dw/@countrystatecity/translations?label=translations)](https://www.npmjs.com/package/@countrystatecity/translations)\n\nCountry name translations in 19 languages — Arabic, Chinese, French, German, Spanish, Japanese, and more.\n\n## ✨ Features\n\n- 🌍 **250 Countries**: Full ISO 3166-1 coverage\n- 🗣️ **19 Languages**: `ar`, `br`, `de`, `es`, `fa`, `fr`, `hi`, `hr`, `it`, `ja`, `ko`, `nl`, `pl`, `pt`, `pt-BR`, `ru`, `tr`, `uk`, `zh-CN`\n- 🔍 **Flexible Lookup**: Find by country code, locale, or translated name\n- 🔄 **Safe Fallback**: Falls back to secondary locale or English name automatically\n- 🚀 **Minimal Bundle**: <3KB initial load with lazy-loaded data file\n- 📦 **ESM + CJS**: Works in Node.js, browsers, and edge runtimes\n- 📝 **TypeScript**: Full type definitions included\n- 🔧 **Tree-Shakeable**: Only bundle what you use\n\n## 📦 Installation\n\n```bash\nnpm install @countrystatecity/translations\n# or\nyarn add @countrystatecity/translations\n# or\npnpm add @countrystatecity/translations\n```\n\n## 🚀 Quick Start\n\n```typescript\nimport {\n  getTranslations,\n  getCountryTranslations,\n  getTranslation,\n  getLocales,\n  searchByTranslatedName,\n  getTranslationOrFallback,\n} from '@countrystatecity/translations';\n\n// Get translated name for a country in a specific locale\nconst name = await getTranslation('DE', 'fr');\nconsole.log(name); // \"Allemagne\"\n\n// Get all translations for a country\nconst entry = await getCountryTranslations('JP');\nconsole.log(entry);\n// {\n//   iso2: 'JP',\n//   name: 'Japan',\n//   translations: { ar: 'اليابان', fr: 'Japon', de: 'Japan', zh-CN: '日本', ... }\n// }\n\n// Get all countries with translations (e.g. for a French dropdown)\nconst all = await getTranslations();\nconst frenchDropdown = all.map(c => ({\n  iso2: c.iso2,\n  label: c.translations['fr'] ?? c.name,\n}));\n\n// List all available locales\nconst locales = await getLocales();\nconsole.log(locales);\n// ['ar', 'br', 'de', 'es', 'fa', 'fr', 'hi', 'hr', 'it', 'ja', 'ko', 'nl', 'pl', 'pt', 'pt-BR', 'ru', 'tr', 'uk', 'zh-CN']\n```\n\n## 📖 API Reference\n\n### Core Functions\n\n#### `getTranslations()`\n\nGet all 250 country translation records.\n\n```typescript\nconst translations = await getTranslations();\n// Returns: ICountryTranslation[]\n```\n\n#### `getCountryTranslations(iso2: string)`\n\nGet the full translation record for a country by ISO 3166-1 alpha-2 code.\n\n```typescript\nconst entry = await getCountryTranslations('US');\n// Returns: ICountryTranslation | undefined\n```\n\n**Parameters:**\n- `iso2` — ISO 3166-1 alpha-2 country code (e.g., `'US'`, `'DE'`). Case-insensitive.\n\n#### `getTranslation(iso2: string, locale: string)`\n\nGet the translated country name for a specific locale.\n\n```typescript\nconst name = await getTranslation('FR', 'de'); // \"Frankreich\"\nconst name = await getTranslation('IN', 'hi'); // \"भारत\"\nconst name = await getTranslation('JP', 'zh-CN'); // \"日本\"\n// Returns: string | undefined\n```\n\n**Parameters:**\n- `iso2` — ISO 3166-1 alpha-2 country code. Case-insensitive.\n- `locale` — Locale code (e.g., `'fr'`, `'de'`, `'zh-CN'`).\n\n#### `getLocales()`\n\nGet all available locale codes.\n\n```typescript\nconst locales = await getLocales();\n// Returns: string[]  — sorted array of 19 locale codes\n```\n\n#### `searchByTranslatedName(query: string, locale?: string)`\n\nSearch for countries by translated name (case-insensitive, partial match).\n\n```typescript\nconst results = await searchByTranslatedName('Allemagne', 'fr');\n// Returns: ICountryTranslation[]  — [{ iso2: 'DE', ... }]\n\n// Search across all locales when no locale given\nconst results = await searchByTranslatedName('united');\n// Returns: ICountryTranslation[]  — [US, GB, AE, ...]\n```\n\n### Utility Functions\n\n#### `getTranslationOrFallback(entry, locale, fallbackLocale?)`\n\nSync helper — returns the translation for the given locale, falling back to `fallbackLocale` if provided, then to the English `name`.\n\n```typescript\nconst entry = await getCountryTranslations('US');\n\ngetTranslationOrFallback(entry, 'fr');           // \"États-Unis\"\ngetTranslationOrFallback(entry, 'xx', 'fr');     // \"États-Unis\" (fell back to fr)\ngetTranslationOrFallback(entry, 'xx');           // \"United States\" (fell back to English)\n// Returns: string  — never undefined\n```\n\n## 🌍 Real-World Examples\n\n### Localized Country Dropdown\n\n```typescript\nimport { getTranslations } from '@countrystatecity/translations';\n\nasync function getCountryOptions(locale: string) {\n  const all = await getTranslations();\n  return all.map(c => ({\n    value: c.iso2,\n    label: c.translations[locale] ?? c.name,\n  }));\n}\n\nconst options = await getCountryOptions('fr');\n// [{ value: 'AF', label: 'Afghanistan' }, { value: 'AL', label: 'Albanie' }, ...]\n```\n\n### Country Name in User's Language\n\n```typescript\nimport { getTranslation, getTranslationOrFallback, getCountryTranslations } from '@countrystatecity/translations';\n\nasync function getLocalizedCountryName(iso2: string, userLocale: string) {\n  const entry = await getCountryTranslations(iso2);\n  if (!entry) return null;\n  return getTranslationOrFallback(entry, userLocale, 'en');\n}\n\nconsole.log(await getLocalizedCountryName('DE', 'fr')); // \"Allemagne\"\nconsole.log(await getLocalizedCountryName('DE', 'ja')); // \"ドイツ\"\nconsole.log(await getLocalizedCountryName('DE', 'xx')); // \"Germany\" (fallback)\n```\n\n### Search Countries by Translated Name\n\n```typescript\nimport { searchByTranslatedName } from '@countrystatecity/translations';\n\n// Find all countries whose German name contains \"land\"\nconst results = await searchByTranslatedName('land', 'de');\n// → [Ireland (Irland), Iceland (Island), Finland (Finnland), ...]\n\n// Find across all locales\nconst results = await searchByTranslatedName('Stati Uniti');\n// → [{ iso2: 'US', name: 'United States', translations: { it: 'Stati Uniti', ... } }]\n```\n\n### i18n Integration\n\n```typescript\nimport { getTranslation } from '@countrystatecity/translations';\n\n// Works with any i18n framework — just pass the active locale\nasync function formatAddress(countryCode: string, locale: string) {\n  const countryName = await getTranslation(countryCode, locale);\n  return countryName ?? countryCode;\n}\n```\n\n## 🔧 TypeScript Types\n\n```typescript\ninterface ICountryTranslation {\n  iso2: string;                         // \"DE\" — ISO 3166-1 alpha-2\n  name: string;                         // \"Germany\" — English name\n  translations: Record<string, string>; // { \"fr\": \"Allemagne\", \"de\": \"Deutschland\", ... }\n}\n```\n\n## 🗣️ Available Locales\n\n| Code | Language | Code | Language |\n|------|----------|------|----------|\n| `ar` | Arabic | `ko` | Korean |\n| `br` | Breton | `nl` | Dutch |\n| `de` | German | `pl` | Polish |\n| `es` | Spanish | `pt` | Portuguese |\n| `fa` | Persian | `pt-BR` | Portuguese (Brazil) |\n| `fr` | French | `ru` | Russian |\n| `hi` | Hindi | `tr` | Turkish |\n| `hr` | Croatian | `uk` | Ukrainian |\n| `it` | Italian | `zh-CN` | Chinese (Simplified) |\n| `ja` | Japanese | | |\n\n## 📊 Bundle Size\n\n| Action | Bundle Size |\n|--------|-------------|\n| Install package + import function | ~3KB |\n| Load all translations | ~158KB |\n| **Typical usage** | **~3KB** |\n\n### Data Coverage\n\n- **250 countries**: Full ISO 3166-1 coverage\n- **19 locales**: Major world languages\n- **Auto-updated**: Synced weekly from [Countries States Cities Database](https://github.com/dr5hn/countries-states-cities-database)\n\n## 🧪 Testing\n\n```bash\n# Run all tests\nnpm test\n\n# Watch mode\nnpm run test:watch\n```\n\nAll packages include comprehensive tests:\n- ✅ Unit tests for every function\n- ✅ Integration tests\n- ✅ iOS/Safari compatibility tests\n\n## 🔄 CI/CD & Automation\n\n### Continuous Integration\nEvery push and PR automatically:\n- ✅ Runs type checking with TypeScript\n- ✅ Executes comprehensive test suite across Node.js 20 and 22\n- ✅ Builds the package\n\n### Automated Data Updates\nWeekly automated updates (Sundays at 00:00 UTC):\n- 📥 Downloads latest data from [countries-states-cities-database](https://github.com/dr5hn/countries-states-cities-database)\n- 🔄 Regenerates `translations.json` with updated country names\n- 🧪 Runs full test suite\n- 📝 Creates PR for review if changes detected\n\n### Automated Publishing\nAutomated publishing to npm on version bump:\n- 📦 Builds and tests before publishing\n- 🚀 Publishes to npm registry\n- 🏷️ Creates GitHub Release linked to the exact source commit\n\n## 📄 License\n\n[ODbL-1.0](https://github.com/dr5hn/countrystatecity/blob/main/LICENSE) © [dr5hn](https://github.com/dr5hn)\n\nThis package and its data are licensed under the Open Database License (ODbL) v1.0. The data is sourced from the [Countries States Cities Database](https://github.com/dr5hn/countries-states-cities-database) which is also licensed under ODbL-1.0.\n\n## 🤝 Contributing\n\nContributions are welcome! Please open an issue or PR.\n\n**For data-related issues** (incorrect translations, missing locales, etc.), please report them to the [Countries States Cities Database](https://github.com/dr5hn/countries-states-cities-database/issues) repository, which is the authoritative source of data for this package.\n\n## 📦 Package Ecosystem\n\nThis package is part of the [@countrystatecity package ecosystem](https://github.com/dr5hn/countrystatecity-npm):\n\n- **[@countrystatecity/countries](https://www.npmjs.com/package/@countrystatecity/countries)** — Server-side countries, states, and cities database. Bundle: <10KB initial load.\n\n- **[@countrystatecity/timezones](https://www.npmjs.com/package/@countrystatecity/timezones)** — Comprehensive timezone data with conversion utilities. Bundle: <20KB initial load.\n\n- **[@countrystatecity/currencies](https://www.npmjs.com/package/@countrystatecity/currencies)** — ISO 4217 currency data with symbols and country mappings. Bundle: <3KB initial load.\n\n- **[@countrystatecity/translations](https://www.npmjs.com/package/@countrystatecity/translations)** (This package) — Country name translations in 19 languages. Bundle: <3KB initial load.\n\n## 🔗 Links\n\n- [GitHub Repository](https://github.com/dr5hn/countrystatecity-npm/tree/main/packages/translations)\n- [Issues](https://github.com/dr5hn/countrystatecity-npm/issues)\n- [NPM Package](https://www.npmjs.com/package/@countrystatecity/translations)\n- [NPM Organization](https://www.npmjs.com/org/countrystatecity)\n","readmeFilename":"README.md"}