Socket
Book a DemoInstallSign in
Socket

formatter-stream

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

formatter-stream

Stream that transforms objects into strings using pre-defined format.

latest
Source
npmnpm
Version
1.0.0
Version published
Weekly downloads
1
-66.67%
Maintainers
1
Weekly downloads
 
Created
Source

formatter-stream

Stream that transforms objects into strings using pre-defined format. Useful for streaming logs.

Installation

$ npm install formatter-stream --save

Usage

var FormatterStream = require('formatter-stream');

var stream = new FormatterStream(':author wrote ":book"');

stream.on('data', function (data) {
	data.toString() === 'Arthur Conan Doyle wrote "Sherlock Holmes"'; // true
});

stream.write({
	author: 'Arthur Conan Doyle',
	book: 'Sherlock Holmes'
});

stream.end();

Tests

$ npm test

License

formatter-stream is released under the MIT license.

Keywords

stream

FAQs

Package last updated on 29 Mar 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts