co-dns

0.0.2 • Public • Published

co-dns

Node core dns wrapped functions that return thunks for co.

Installation

$ npm install co-dns --save

Example

Use all the regular async dns functions without callback hell:

var wrap = require('co-dns')
var dns = wrap(require('dns'))
 
var hostnames = yield dns.reverse('8.8.8.8') // returns an array
 
// returns an array, where ip[0] is the ip address and ip[1] is the family (ipv4 or ipv6)
var ip = yield dns.lookup('bing.com')

License

MIT

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.0.2
    0
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.0.2
    0
  • 0.0.1
    0

Package Sidebar

Install

npm i co-dns

Weekly Downloads

0

Version

0.0.2

License

MIT

Last publish

Collaborators

  • jksdua