Socket
Book a DemoInstallSign in
Socket

json-parser-stream

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

json-parser-stream

JSON.parse transform stream

0.1.0
latest
npmnpm
Version published
Weekly downloads
0
-100%
Maintainers
1
Weekly downloads
 
Created
Source

JSON Parser Stream

Parse a readable stream of json strings into javascript objects

NPM

Build Status Dependency Status Code Climate

Installation

npm install -S json-parser-stream

Usage

Create an instance of linestream and pipe a readable stream into that instance

var JSONParserStream = require('json-parser-stream')
// parser is an instance of require('stream').Transform
var opts = {
  highWaterMark: 2
}
var parser = new JSONParserStream(opts) // opts is optional

var readStream = {} // a stream of single json strings per data event
var parser = readStream.pipe(splitter)
parser.on('data', function(chunk) {
  console.dir(chunk)  // no line breaks here :)
})
parser.on('finish', function() {
  console.log('finish event called, all json items read')
})

Keywords

stream

FAQs

Package last updated on 09 Jan 2014

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

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.