Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

updated example in readme

  • Loading branch information...
commit 36074db142ed6a60b6685ed11b7286fd7d80026e 1 parent 49d122f
@einaros authored
Showing with 14 additions and 0 deletions.
  1. +14 −0 README.md
View
14 README.md
@@ -8,6 +8,20 @@ Simple rate limiting for node.js streams, capable of capping both read and write
# Usage
+## http (see examples/http for a more elaborate example)
+
+ var http = require('http')
+ , ratelimit = require('../../');
+
+ http.get('http://someplace.com/path/file.zip', function(res) {
+ var limit = ratelimit(res, 65 * 1024);
+ res.on('data', function(data) {
+ // do whatever with data
+ });
+ });
+
+## other examples
+
See the tests for now.
# Todo
Please sign in to comment.
Something went wrong with that request. Please try again.