@macrostrat/dbgeo-stream

1.0.0 • Public • Published

dbgeo-stream

A simplified streaming version of dbgeo for use with node-pg-query-stream. Takes as an input a readable object stream, and each object must have a property geom which is a WKB geometry. Will output a valid GeoJSON FeatureCollection as a stream that can be piped directly to a file or HTTP response.

Installation
npm install @macrostrat/dbgeo-stream
Example Usage
const dbgeoStream = require('@macrostrat/dbgeo-stream')

// Connect to Postgres, etc...
let query = new QueryStream('SELECT id, geom FROM land', [])
client.query(query)
  .pipe(dbgeoStream)
  .pipe(res)

License

MIT

Package Sidebar

Install

npm i @macrostrat/dbgeo-stream

Weekly Downloads

17

Version

1.0.0

License

MIT

Last publish

Collaborators

  • idzikowski.casey
  • jczaplew
  • davenquinn