Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

io-cep

Package Overview
Dependencies
Maintainers
1
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

io-cep - npm Package Compare versions

Comparing version 2.2.0 to 2.2.1

11

package.json
{
"name": "io-cep",
"version": "2.2.0",
"version": "2.2.1",
"description": "Busca por informações de uma localidade através do endereço ou CEP utilizando os Correios",

@@ -23,5 +23,8 @@ "keywords": [

"main": "index.js",
"directories": {
"lib": "./lib"
},
"files": [
"index.js",
"lib",
"license",
"readme.md"
],
"repository": "lagden/io-cep",

@@ -28,0 +31,0 @@ "scripts": {

@@ -1,14 +0,28 @@

# io-cep [![NPM version](https://img.shields.io/npm/v/io-cep.svg)](https://www.npmjs.com/package/io-cep)
[![Build Status](https://travis-ci.org/lagden/io-cep.svg?branch=master)](https://travis-ci.org/lagden/io-cep)
[![Coverage Status](https://coveralls.io/repos/lagden/io-cep/badge.svg?branch=master&service=github)](https://coveralls.io/github/lagden/io-cep?branch=master)
[![Dependency Status](https://david-dm.org/lagden/io-cep.svg)](https://david-dm.org/lagden/io-cep)
[![devDependency Status](https://david-dm.org/lagden/io-cep/dev-status.svg)](https://david-dm.org/lagden/io-cep#info=devDependencies)
# io-cep
> Busca por informações de uma localidade através do endereço ou CEP utilizando os [Correios](http://www.correios.com.br/)
[![NPM version][npm-img]][npm]
[![Build Status][ci-img]][ci]
[![Coverage Status][coveralls-img]][coveralls]
[![devDependency Status][devDep-img]][devDep]
[![XO code style][xo-img]][xo]
[npm-img]: https://img.shields.io/npm/v/io-cep.svg
[npm]: https://www.npmjs.com/package/io-cep
[ci-img]: https://travis-ci.org/lagden/io-cep.svg
[ci]: https://travis-ci.org/lagden/io-cep
[coveralls-img]: https://coveralls.io/repos/github/lagden/io-cep/badge.svg?branch=master
[coveralls]: https://coveralls.io/github/lagden/io-cep?branch=master
[devDep-img]: https://david-dm.org/lagden/io-cep/dev-status.svg
[devDep]: https://david-dm.org/lagden/io-cep#info=devDependencies
[xo-img]: https://img.shields.io/badge/code_style-XO-5ed9c7.svg
[xo]: https://github.com/sindresorhus/xo
Busca por informações de uma localidade através do endereço ou CEP utilizando os [Correios](http://www.correios.com.br/)
## Install
```
$ npm i --save-dev io-cep
$ npm i -S io-cep
```

@@ -20,18 +34,15 @@

```javascript
var consulta = require('io-cep');
const consulta = require('io-cep')
consulta('01310-940')
.then(function(res){
if(res.success) {
process.stdout.write(res.dados[0].logradouro + '\n');
//=> Avenida Paulista
consulta(01310940)
.then(res => {
if (res.success) {
console.log(res.dados[0].logradouro) // Avenida Paulista
} else {
process.stdout.write(res.message + '\n');
//=> Dados não encontrado ou erro de análise.
console.log(res.message) // Dados não encontrado ou erro de análise.
}
})
.catch(function(err){
process.stdout.write(err + '\n');
});
});
.catch(err => {
console.log(err)
})
```

@@ -38,0 +49,0 @@

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc