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

12 lines (9 loc) 262 B
import { sanitize, subtreeText } from '../../commons/text'; function hasTextContentEvaluate(node, options, virtualNode) { try { return sanitize(subtreeText(virtualNode)) !== ''; } catch (e) { return undefined; } } export default hasTextContentEvaluate;