UNPKG

@satheshsat/angular-cnpj

Version:

CNPJ generator and validator

33 lines (21 loc) 796 B
# CNPJ [![](https://img.shields.io/static/v1?label=Sponsor&message=%E2%9D%A4&logo=GitHub&color=%23fe8e86)](https://github.com/sponsors/satheshsat) [![NPM](https://img.shields.io/npm/v/@satheshsat/angular-cnpj.svg)](https://www.npmjs.com/package/@satheshsat/angular-cnpj) [![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com) ## Install ```bash npm install --save @satheshsat/angular-cnpj ``` ## Usage ```ts import { Injectable } from '@angular/core'; import CnpjService from '@satheshsat/angular-cnpj'; @Injectable({ providedIn: 'root' }) export class ExampleService { constructor(public cnpj: CnpjService) { cnpj.validate(cnpj.generate()); } } ``` ## License MIT © [satheshsat](https://github.com/satheshsat)