Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

Brazilian docs validator for Go - CPF, CNPJ, CEP, RENAVAM, CNH and license plate!

License

NotificationsYou must be signed in to change notification settings

paemuri/brdoc

Repository files navigation

Licensego.devGo Report Card

CPF, CNPJ, CEP, CNH, PIS/PASEP, RENAVAM, CNS, license plate and voter ID validator for Go!

Everything in this file, but theLicense section, is inportuguese.

Descrição

BR Doc é um pacote para validação, tanto do formato quanto dos dígitos,de documentos brasileiros, como CPF, CNPJ, CEP, CNH, PIS/PASEP, RENAVAM, placaveicular, RG (só SP e RJ) e título de eleitor.

Aceito PRs de todas as formas. Está permitido escrever em português,também. :)

Uso

Principais funções:

  • func IsCPF(doc string) bool
  • func IsCNPJ(doc string) bool
  • func IsCEP(doc string, ufs ...FederativeUnit) bool
  • func IsCNH(doc string) bool
  • func IsPIS(doc string) bool
  • func IsRENAVAM(doc string) bool
  • func IsPlate(doc string) bool
  • func IsNationalPlate(doc string) bool
  • func IsMercosulPlate(doc string) bool
  • func IsCNS(doc string) bool
  • func IsRG(doc string, uf FederativeUnit) bool
  • func IsVoterID(doc string) bool

Coisas a fazer

  • validação de CPF
  • validação de CNPJ
  • validação de CEP
  • validação de CNH (obrigado @eminetto!)
  • validação de RENAVAM (obrigado @leogregianin!)
  • validação de placa veicular
  • validação de CNS (obrigado @renatosuero!)
  • validação de título de eleitor (obrigado @tiagompalte!)
  • validação de RG
    • SP (obrigado @robas!)
    • RJ (obrigado @robas!)
    • demais estados

License

This project code is in the public domain. See theLICENSE file.

Contribution

Unless you explicitly state otherwise, any contribution intentionallysubmitted for inclusion in the work by you shall be in the publicdomain, without any additional terms or conditions.

About

Brazilian docs validator for Go - CPF, CNPJ, CEP, RENAVAM, CNH and license plate!

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages


[8]ページ先頭

©2009-2025 Movatter.jp