1.0.0 • Published 7 years ago

sockbat v1.0.0

Weekly downloads
4
License
MIT
Repository
github
Last release
7 years ago

sockbat

Synopsis

Server will listen on the specified port and handles connections.

Installation

npm install --save sockbat

Usage

	import Sockbat from 'sockbat'
	
	# accepts a JavaScript object as an argument:

	const options = {
	  port: process.env.PORT,
	  logger: winston,
	  hostname: process.env.HOSTNAME,
	  packageName: pkg.name,
	}
	
	const sockbat = new Sockbat(options)
	
	sockbat.listen(port, hostname)
	
	sockbat.on('connection', () => {
		console.log('connected')
	})
	

Dependencies

* duplex-emitter
* chalk
1.0.0

7 years ago

0.1.1

7 years ago

0.1.0

7 years ago

0.0.5

7 years ago

0.0.4

7 years ago

0.0.3

7 years ago

0.0.2

7 years ago

0.0.1

7 years ago