How to use the stream-json/utils/StreamJsonObjects.make function in stream-json

To help you get started, we’ve selected a few stream-json examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Sn8z / Poddr / node_modules / electron-builder-lib / out / remoteBuilder / RemoteBuildManager.js View on Github external
stream.on("response", headers => {
        const status = headers[HTTP2_HEADER_STATUS];

        if (status !== HTTP_STATUS_OK) {
          reject(new (_builderUtilRuntime().HttpError)(status));
          return;
        }

        const objectStream = StreamJsonObjects.make();
        objectStream.output.on("data", object => {
          const data = object.value;

          if (_builderUtil().log.isDebugEnabled) {
            _builderUtil().log.debug({
              event: JSON.stringify(data, null, 2)
            }, "remote builder event");
          }

          if (data.status != null) {
            _builderUtil().log.info({
              status: data.status
            }, "remote building");
          } else if ("error" in data) {
            resolve({
              files: null,

stream-json

stream-json is the micro-library of Node.js stream components for creating custom JSON processing pipelines with a minimal memory footprint. It can parse JSON files far exceeding available memory streaming individual primitives using a SAX-inspired API. I

BSD-3-Clause
Latest version published 13 days ago

Package Health Score

80 / 100
Full package analysis