{"_id":"@data-sets/countries","_rev":"4-aed40e97ac22311afc1788d76fdd359e","name":"@data-sets/countries","dist-tags":{"latest":"1.0.0"},"versions":{"0.1.0":{"name":"@data-sets/countries","version":"0.1.0","keywords":["static","data","sets","countries"],"author":{"url":"https://jdrydn.com","name":"James D","email":"james@jdrydn.com"},"license":"MIT","_id":"@data-sets/countries@0.1.0","maintainers":[{"name":"jdrydn","email":"james@jdrydn.com"}],"homepage":"https://github.com/someimportantcompany/data-sets/tree/master/countries","bugs":{"url":"https://github.com/someimportantcompany/data-sets/issues"},"nyc":{"exclude":["*.test.js"],"reporter":["lcov","text"]},"dist":{"shasum":"f6537a8947d6847d9bbf6247532674bf8e2bc326","tarball":"https://registry.npmjs.org/@data-sets/countries/-/countries-0.1.0.tgz","fileCount":6,"integrity":"sha512-KGBv0wS/g/WZJzEtJG6wVfk+UANXmgEsmGeX9SDyyidJ8z+D4gLKTOW8IsWye+1plsEiQj2x1uZVibcG5917kg==","signatures":[{"sig":"MEYCIQCUx4j0nGoTlu/Wn/Q5QzLdhGSM/1zbHLakwplQ0JPWpQIhAOqsP4fA3qK64qFKJfOOmY0vPH7Jd0bCs0bLPFhguCco","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":84096,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJg1Y0jCRA9TVsSAnZWagAATbgP/RBy084maCaJfTfhz0VU\nOJ4qd6ii4ZLFkWARSeTN6En5EqGgbHxOC6mPFFpTxlekr5hyizjw2k24krVT\nqLFeL294BMEVEeFpC2HV5CZPmGsOrUxmehZnvN1lNHfRjjrXmKlOAus0yvzn\nrcQma0yYrjXJxyBKLhshaGw3W0BI3T5heBjwC0Wih87d12p0l3RBMpoS95KW\nwOAP1MCVS/BZgzLLaANe1szbGiNMYObbJzPnS/i44krY/PLLvs5gL0QeRpLK\nSj3OXhfvNrYblXQfvuTPKeLOyfFVPobBcAlK3gwtKezXuYGaWaJh05LFbChg\npANgDM83XAKINdde/pJZCu0U/mX8hljC3gUfpow+EpBSoBPHJzpPXpiYkjAF\nsSmZ47Qvnps72j8nPOYKoV6GOHhoQXGeptukxPIcYbuSCtg4WFJ2ExyhB9Af\n4eUbEBxeDm5AGWD34olVLSIO7oB864HtKJXNxKqe3MhY6EE8Y3Kqfy0+GbPN\nNj4yBmm9ZpWVGrYDDcGCankSfNoBsYSDQjNB/RlmNO7QQqJQDF6PoH86aSlL\nXTTi3sJto7fhF0bgz7tPPKQT6zcFunDkXg8YXUw9VY4Hu9mBWonNR7TYsJCA\nQSy01KYeHYnZIbyfKVAZe+94kyuom4hjMx8Elg3PbILrIGwmaUwPptTpBOnZ\nJqVZ\r\n=JssO\r\n-----END PGP SIGNATURE-----\r\n"},"main":"countries.js","mocha":{"ui":"bdd","exit":true,"spec":["*.test.js"],"require":["module-alias/register"]},"engines":{"npm":">= 6.0.0","node":">= 8.0.0"},"scripts":{"lint":"eslint --ext .js .","test":"nyc mocha","preversion":"npm run lint && npm test","postversion":"git push && git push --tags"},"_npmUser":{"name":"jdrydn","email":"james@jdrydn.com"},"repository":{"url":"git+https://github.com/someimportantcompany/data-sets.git","type":"git"},"_npmVersion":"6.14.11","description":"Static data-set of countries, with additional methods for convenience.","directories":{},"_nodeVersion":"12.20.0","browserslist":["maintained node versions"],"dependencies":{},"_hasShrinkwrap":false,"_moduleAliases":{"@data-sets/countries":"./"},"devDependencies":{"nyc":"^15.1.0","mocha":"^6.2.3","eslint":"^5.16.0","csv-parse":"^4.16.0","babel-eslint":"^10.1.0","module-alias":"^2.2.2","eslint-plugin-mocha":"^5.3.0","eslint-plugin-sort-requires":"^2.1.0"},"_npmOperationalInternal":{"tmp":"tmp/countries_0.1.0_1624608035192_0.6115216183261569","host":"s3://npm-registry-packages"}},"0.3.0":{"name":"@data-sets/countries","version":"0.3.0","keywords":["static","data","sets","countries"],"author":{"url":"https://jdrydn.com","name":"James D","email":"james@jdrydn.com"},"license":"MIT","_id":"@data-sets/countries@0.3.0","maintainers":[{"name":"jdrydn","email":"james@jdrydn.com"}],"homepage":"https://github.com/someimportantcompany/data-sets/tree/master/countries","bugs":{"url":"https://github.com/someimportantcompany/data-sets/issues"},"dist":{"shasum":"fc774b66643eed4fd3c13cb0c72d0e4822813b33","tarball":"https://registry.npmjs.org/@data-sets/countries/-/countries-0.3.0.tgz","fileCount":8,"integrity":"sha512-fn9Z/aQgKYc//t3X8GeIugdrQEVFZ/YmF39ASZl3Gq7zHUyJFtgXqjkIy3JQK9L6Uls6zE8D7oAJv16/hycmQA==","signatures":[{"sig":"MEUCIQC3UUW1KzznGjtzbo3dOAfycuX4IAr316xnIiU2LVLbbAIgRWxFGPXe8kSyDtEovhaIGEE/8Cy4yhSnKwI3PQNp45U=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":177321},"main":"./index.cjs","mocha":{"exit":true,"spec":["./{,!(node_modules)/**}/*.test.{,+(js|ts)}"],"ignore":["**/node_modules"],"require":["ts-node/register","tsconfig-paths/register"],"reporter":"spec","recursive":true},"types":"./index.d.ts","engines":{"npm":">= 8.0.0","node":">= 12.0.0"},"gitHead":"93dbcbed2d2575a651d5e5824504f9c99b14c324","scripts":{"lint":"eslint --ext .js,.ts .","test":"mocha","build":"ts-node -r tsconfig-paths/register ./build.ts","preversion":"npm run lint && npm test","postversion":"git push && git push --tags"},"_npmUser":{"name":"jdrydn","email":"james@jdrydn.com"},"repository":{"url":"git+https://github.com/someimportantcompany/data-sets.git","type":"git"},"_npmVersion":"8.19.4","description":"Static data-set of countries, with additional methods for convenience.","directories":{},"_nodeVersion":"16.20.1","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/countries_0.3.0_1693769168456_0.7298582612888525","host":"s3://npm-registry-packages"}},"1.0.0":{"name":"@data-sets/countries","version":"1.0.0","description":"Static data-set of countries, with lookup methods for convenience.","type":"module","main":"./index.js","types":"./index.d.ts","repository":{"type":"git","url":"git+https://github.com/someimportantcompany/data-sets.git"},"bugs":{"url":"https://github.com/someimportantcompany/data-sets/issues"},"homepage":"https://github.com/someimportantcompany/data-sets/tree/main/packages/countries","author":{"name":"jdrydn","email":"james@jdrydn.com","url":"https://jdrydn.com"},"license":"MIT","keywords":["static","data","sets","countries"],"exports":{".":{"types":"./index.d.ts","default":"./index.js"},"./data.json":"./data.json"},"engines":{"node":">= 18.0.0"},"scripts":{"lint":"eslint .","test":"vitest run --dir ."},"_id":"@data-sets/countries@1.0.0","_integrity":"sha512-KJLkwf4k9IBq3tpTQ+P6s9XJGGZ2lkgmIIAFf2caUFtnIBiEPa8uT2S83KRU+SkOvjcyybkAAW4l9pVb5JcF7Q==","_resolved":"/private/var/folders/vw/knq65j7j1j7b25swvcbbz9hm0000gn/T/e4efc6ca7efbf9722deabe5b47a4797f/data-sets-countries-1.0.0.tgz","_from":"file:data-sets-countries-1.0.0.tgz","_nodeVersion":"20.19.6","_npmVersion":"10.8.2","dist":{"integrity":"sha512-KJLkwf4k9IBq3tpTQ+P6s9XJGGZ2lkgmIIAFf2caUFtnIBiEPa8uT2S83KRU+SkOvjcyybkAAW4l9pVb5JcF7Q==","shasum":"d78dfe0b4cbe39f650908c3c7a0aafa827286a7e","tarball":"https://registry.npmjs.org/@data-sets/countries/-/countries-1.0.0.tgz","fileCount":8,"unpackedSize":48976,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQC63lQKn0Osg3DGqJyVYSQU7UDk4+zlmSZOFWC4ZfHEVgIgAWsETvQhNX2/6Qr37LfnIhmLbaufCFd2JSRUtwuMgjE="}]},"_npmUser":{"name":"jdrydn","email":"james@jdrydn.com"},"directories":{},"maintainers":[{"name":"jdrydn","email":"james@jdrydn.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/countries_1.0.0_1773440832738_0.3474080266856745"},"_hasShrinkwrap":false}},"time":{"created":"2021-06-25T08:00:34.777Z","modified":"2026-03-13T22:27:13.025Z","0.1.0":"2021-06-25T08:00:35.401Z","0.3.0":"2023-09-03T19:26:08.770Z","1.0.0":"2026-03-13T22:27:12.883Z"},"bugs":{"url":"https://github.com/someimportantcompany/data-sets/issues"},"author":{"name":"jdrydn","email":"james@jdrydn.com","url":"https://jdrydn.com"},"license":"MIT","homepage":"https://github.com/someimportantcompany/data-sets/tree/main/packages/countries","keywords":["static","data","sets","countries"],"repository":{"type":"git","url":"git+https://github.com/someimportantcompany/data-sets.git"},"description":"Static data-set of countries, with lookup methods for convenience.","maintainers":[{"name":"jdrydn","email":"james@jdrydn.com"}],"readme":"# @data-sets/countries\n\nStatic data-set of countries (ISO 3166), with lookup methods for convenience.\n\n## Install\n\n```bash\nnpm install @data-sets/countries\n# or\npnpm add @data-sets/countries\n```\n\n## Usage\n\n```js\nimport { data, findByCode, findByName, findByContinent } from '@data-sets/countries';\n\n// Find a country by ISO 3166-1 alpha-2 or alpha-3 code\nconst gb = findByCode('GB');\n// { name: 'United Kingdom', iso2: 'GB', iso3: 'GBR', continent: 'Europe', ... }\n\nconst usa = findByCode('USA');\n// { name: 'United States of America', iso2: 'US', iso3: 'USA', ... }\n\n// Find a country by name (case-insensitive)\nconst japan = findByName('japan');\n// { name: 'Japan', iso2: 'JP', iso3: 'JPN', continent: 'Asia', ... }\n\n// Find all countries on a continent\nconst european = findByContinent('Europe');\n// [ { name: 'Albania', ... }, { name: 'Andorra', ... }, ... ]\n```\n\nA default export is also available:\n\n```js\nimport countries from '@data-sets/countries';\n\ncountries.findByCode('FR');\n```\n\n## Data Shape\n\nEach record has the following shape:\n\n```ts\ntype CountryRecord = {\n  name: string;\n  iso2: string;        // ISO 3166-1 alpha-2 (e.g. \"GB\")\n  iso3: string;        // ISO 3166-1 alpha-3 (e.g. \"GBR\")\n  continent: string;\n  capitalCity: string;\n  phonePrefix: string; // e.g. \"+44\"\n  currencyCode: string;\n  population: number;\n};\n```\n\n## Raw Data\n\nYou can also import the raw JSON directly:\n\n```js\nimport data from '@data-sets/countries/data.json';\n```\n\n## License\n\nMIT\n","readmeFilename":"README.md"}