UNPKG

luhn-generator

Version:

A generator of numbers that passes the validation of Luhn algorithm or Luhn formula, also known as the 'modulus 10' or 'mod 10' algorithm

18 lines (14 loc) 355 B
import { isDataTable, toArray } from '../commons/table'; function dataTableLargeMatches(node) { if (isDataTable(node)) { var tableArray = toArray(node); return ( tableArray.length >= 3 && tableArray[0].length >= 3 && tableArray[1].length >= 3 && tableArray[2].length >= 3 ); } return false; } export default dataTableLargeMatches;