Socket
Socket
Sign inDemoInstall

@cryptohub/countries-divisions

Package Overview
Dependencies
0
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @cryptohub/countries-divisions

A comprehensive JSON module containing primary administrative divisions for countries based on the ISO 3166-1 Alpha-2 standard.


Version published
Maintainers
1
Created

Readme

Source

Countries Divisions

A comprehensive JSON module containing primary administrative divisions for countries based on the ISO 3166-1 Alpha-2 standard.

Installation

To use this module in your project, you can install it via npm:

npm install @cryptohub/countries-divisions

Usage

Once installed, you can require it in your JavaScript/Node.js project:

const countriesDivisions = require('@cryptohub/countries-divisions');
console.log(countriesDivisions['US']); // Example output: { type_en: "State", type_local: "State" }

Data Structure

The module exports a JSON object with the structure:

{
    "ISO_3166-1_Alpha-2_Code": {
        "type_en": "Division Name in English",
        "type_local": "Division Name in Local Language"
    },}

For example:

{
    "US": {
        "type_en": "State",
        "type_local": "State"
    },}

Exclusions

The following countries are excluded from the list due to lack of divisions:

  • GI (Gibraltar)
  • MF (Saint Martin (French part))
  • NF (Norfolk Island)
  • PM (Saint Pierre and Miquelon)
  • VA (Holy See (Vatican City State))

License

This project is licensed under the CORE License. Please see the LICENSE file for more details.

Contributing

  1. Fork the repository.
  2. Clone your fork.
  3. Create a new branch.
  4. Make your changes.
  5. Commit and push your changes.
  6. Create a pull request.

Keywords

FAQs

Last updated on 21 Sep 2023

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc