GitXplorerGitXplorer
m

json-stream

public
49 stars
13 forks
5 issues

Commits

List of commits on branch master.
Unverified
08a3308f1e8bdd01f96a67c7f58f6344eddbd8e1

Merge pull request #8 from tomekwi/patch-1

jjcrugzz committed 10 years ago
Unverified
d0e114cc705efbe389167e574d4c8cfbaa1dbf89

Display master build status

committed 10 years ago
Unverified
5ee38765af8b6c05f4a895d25c284063e2a16738

[dist] Version bump. 1.0.0

jjcrugzz committed 10 years ago
Unverified
4eb9071358439881ec2af1b9896b8043b3f2f084

[doc] minor fix

jjcrugzz committed 10 years ago
Unverified
f035a5a7577a2b7324626f7918cdf27b3d8607e6

Merge pull request #7 from jcrugzz/async-option

mmmalecki committed 10 years ago
Unverified
66940d505a7f7ef904392a3c9a6d227c04143d80

[test] duplicate a test case but use the async option

jjcrugzz committed 10 years ago

README

The README file for this repository.

json-stream Build Status

New line-delimeted JSON parser with a stream interface.

Installation

npm install json-stream

Usage

var JSONStream = require('json-stream');

var stream = JSONStream();

stream.on('data', function (chunk) {
  console.dir(chunk);
});
stream.write('{"a":');
stream.write('42}\n');
stream.write('{"hel');
stream.write('lo": "world"}\n');

Will output:

{ a: 42 }
{ hello: 'world' }

If invalid JSON gets written, it's silently ignored.