A check digit algorithm, Modulus10
import { Modulus10 } from "https://code4fukui.github.io/Modulus10/Modulus10.js";
console.log(Modulus10.calc("978477101067")); // 3
console.log(Modulus10.check("9784771010673")); // true
console.log(Modulus10.addCheckDigit("978477101067")); // "9784771010673"
deno test