mux-demux-net

Generate TCP servers that serve MDM streams

npm install mux-demux-net
1 downloads in the last day
6 downloads in the last week
23 downloads in the last month

mux-demux-net

Generate TCP servers that serve MDM streams.

Because opening net servers and piping is too much work!

Example Client

var MuxDemux = require("mux-demux-net")
    , mdm = MuxDemux(8642)

var stream = mdm.createStream("winning")
stream.on("data", console.log.bind(console, "[CLIENT]"))
stream.write("client")

Example server

var MuxDemux = require("..")

MuxDemux(function (stream) {
    stream.on("data", console.log.bind(console, "[SERVER]"))
    stream.write("server")
}, 8642)

Installation

npm install mux-demux-net

Tests

make test

Contributors

  • Raynos

MIT Licenced

npm loves you