gs1-price-verifier
TypeScript icon, indicating that this package has built-in type declarations

1.1.0 • Public • Published

gs1-price-verifier

A simple npm module for creating check digits for four-digit or five-digit price fields, otherwise known as 'price verifiers'.

For more information, please see the official GS1 standard.

Installation

npm install gs1-price-verifier

import gs1PriceVerifier from 'gs1-price-verifier'

Usage

gs1PriceVerifier(priceDigits)

priceDigits should be a four or five digit purely numeric string (e.g. "1234" or "12345") depending on your barcode setup. Values before the first significant digit should be padded with 0s.

For example, in a 4 digit system, $12.34 would be "1234" and $1.23 would be "0123"

In a 5 digit system, $12.34 would be "01234" and $1.23 would be "00123".

/gs1-price-verifier/

    Package Sidebar

    Install

    npm i gs1-price-verifier

    Weekly Downloads

    7

    Version

    1.1.0

    License

    MIT

    Unpacked Size

    5.42 kB

    Total Files

    5

    Last publish

    Collaborators

    • oliverhardman