docs: function isCreditCard(val) {
    const digits = val.replace(/\D/g, '');
    const types = creditCardType(digits);
    if (!isArray(types) || isEmpty(types)) return false;
    let match = false;
    for (let t = 0; t < types.length; t++) {
      if (match) break;
      const type = types[t];
      // can match any one of the lengths
      if (!isArray(type.lengths) || isEmpty(type.lengths)) continue;
      for (let l = 0; l < type.lengths.length; l++) {
        const len = type.lengths[l];
        if (isFinite(len) && len === digits.length) {
          match = true;
          break;
        }
      }
    }
  
    return match;
  }