gtin-generator

1.0.4 • Public • Published

GTIN [Global Trade Item Number] Generator

A small utility that generates random GTIN14 and Generates check digit for the input

Installation

$ npm install gtin-generator --save

API

var gtin = require('gtin-generator')

gtin.getGTIN()

Returns a random GTIN-14 with vaild check valid

gtin.calCulateCheckDigit("0441757123021")

Returns calculated check digit for the number provided in string format. Throws error if the argument is not a valid number.

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.4
    110
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 1.0.4
    110
  • 1.0.3
    0
  • 1.0.2
    0
  • 1.0.1
    0
  • 1.0.0
    0

Package Sidebar

Install

npm i gtin-generator

Weekly Downloads

93

Version

1.0.4

License

MIT

Last publish

Collaborators

  • abadri