Miss any of our Open RFC calls?Watch the recordings here! »

gs1

1.0.2 • Public • Published

gs1

Generate check digits for various gs1 formats.

GTIN-8, GTIN-12, GTIN-13, GTIN-14, GSIN, SSCC

usage

const gs1 = require('gs1')
 
console.log(gs1('2345678'));
//23456785
 
console.log(gs1.checkdigit('2345678'));
//5
 
console.log(gs1.validate('23456785'));
//true
 
console.log(gs1.validate('23456783'));
//false

license

MIT

Install

npm i gs1

DownloadsWeekly Downloads

92

Version

1.0.2

License

MIT

Unpacked Size

4.22 kB

Total Files

4

Last publish

Collaborators

  • avatar