A stream interface for irc-message.
JavaScript
Latest commit c086f8c May 29, 2014 @sigkell update README
Permalink
Failed to load latest commit information.
example
.gitignore
LICENSE.md
README.md
index.js
package.json

README.md

irc-message-stream

A tiny Stream interface for irc-message.

Installation

npm install irc-message-stream

Usage

var net = require("net"),
    MessageStream = require("irc-message-stream");

var messageStream = new MessageStream;

messageStream.on("line", function(line) {
    console.log("Got raw line: " + line);
});

messageStream.on("data", function(message) {
    console.log("Got parsed message: " + JSON.stringify(message));
});

var freenode_conn = net.connect(6667, "irc.freenode.net");
freenode_conn.pipe(messageStream);