Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

sergioramos/darius

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

darius

NPM version Build Status Dependency Status Coverage Status

install

npm install darius

example

var darius = require('darius')

var server = darius.createServer().listen(9128, function () {
  console.log('server listening on port 9128')
  
  darius.post('127.0.0.1:9128/hello?from=client', {
    some_key: 'some_value'
  }, function (e) {
    if(!e) console.log('message sent')
  })
})

server.port('/:greeting', function (req) {
  assert.equal(req.params.greeting, 'hello')
  assert.equal(req.query.from, 'client')
  assert.equal(req.body.some_key, 'some_value')
})

license

MIT

About

net server and client helpers

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published