speed-meter

Stream Speed Meter

npm install speed-meter
4 downloads in the last month

Speed Meter

Measure the speed of a readable stream

Install

$ npm install speed-meter --save

Use

var Meter = require('speed-meter');
var stream = require('fs').createReadStream('/path/to/my/file');
var meter = Meter(stream);

var interval = setInterval(function() {
  console.log('reading at ' + meter.speed + ' bytes / sec');
}, 1000);

stream.on('end', function() {
  clearInterval(interval);
});
npm loves you