パッケージの詳細

provinces-ca

justinlettau23.3kMIT1.0.1

List of CA provinces and territories.

canada, ca, provinces, territories

readme

NPM Version CI

CA Provinces

List of CA provinces and territories.

Installation

npm install provinces-ca --save

Usage

import provinces from 'provinces-ca';

console.log(provinces);
// => all provinces and territories

const example1 = provinces.filter((x) => !x.territory);
console.log(example1);
// => provinces only

const example2 = provinces.map((x) => x.abbreviation);
console.log(example2);
// => all provinces/territory abbreviations

The default export from provinces-ca is an array of object with the following structure:

Property Type Description Example
name string Province name. Ontario
abbreviation string Province abbreviation. ON
territory boolean Indicates if the province is a territory. false

Development

npm install
npm run build

更新履歴

Changelog

All notable changes to this project will be documented in this file. See standard-version for commit guidelines.

1.0.1 (2021-12-17)

Bug Fixes

1.0.0 (2020-06-05)

Bug Fixes