Skip to content

AIDC Toolkit / GS1 / isValidPriceOrWeightCheckDigit

Function: isValidPriceOrWeightCheckDigit()

isValidPriceOrWeightCheckDigit(s, checkDigit): boolean

Defined in: src/check.ts:174

Determine if a price or weight check digit is valid for numeric string.

Parameters

s

string

Numeric string exactly four or five characters long.

checkDigit

string

Price or weight check digit.

Returns

boolean

True if the check digit is valid.