Skip to content

Version 0.12.0

Compare
Choose a tag to compare
@VitorLuizC VitorLuizC released this 06 Sep 17:22
· 7 commits to master since this release

Minor Changes

  • Add isCAEPF validator that checks if value is a valid CAEPF.

    isCAEPF('45723174000122')
    //=> true
    
    isCAEPF('457.231.740/001-22')
    //=> false
    
    isCAEPF('45.723.174/0001-22')
    //=> false
    
    isCAEPF('411407182')
    //=> false
    
    isCAEPF('111.111.111/111-11')
    //=> false
  • Add formatToCAEPF formatter that formats a text containing numbers to CAEPF.

    formatToCAEPF('128781')
    //=> '128.781'
    
    formatToCAEPF('32284981000150')
    //=> '322.849.810/001-50'
    
    formatToCAEPF('00.0.000.00.00--00-00')
    //=> '000.000.000/000-00'

    Thanks to @kramer2005 for PR #54.

  • Add support for nodenext module type (for TS consumers).

Patch Changes

  • Fix typo in getRemaining helper function name.

  • Fix typo in isCEP english docs.

  • Fix isCNPJ TSDocs wrongly saying it formats to CPF.

All the changes

0.11.0-beta.0...0.12.0