1.0.6 • Published 3 years ago

phn-validator v1.0.6

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

PHN Validator

This package provides a simple validator for British Columbia provincial health numbers. The validation follows the process on page 23 of this document

Installation

Install my-project with npm

  npm i phn-validator

Or yarn

  yarn add phn-validator

Usage/Examples

import { phnValidator } from 'phn-validator';

phnValidator("123"); // false
phnValidator("0123456789"); // false
phnValidator("apple"); // Error: Input value must be a numeric string
phnValidator(1001); // Error: Input value must be a string
phnValidator("9260784079"); // true
1.0.6

3 years ago

1.0.5

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago