ethereumjs-blockstream
Advanced tools
Comparing version 2.0.1 to 2.0.2
{ | ||
"name": "ethereumjs-blockstream", | ||
"version": "2.0.1", | ||
"version": "2.0.2", | ||
"description": "A library to turn an unreliable remote source of Ethereum blocks into a reliable stream of blocks with removals on re-orgs and backfills on skips.", | ||
@@ -5,0 +5,0 @@ "main": "output/source/index.js", |
@@ -5,2 +5,9 @@ [![npm version](https://badge.fury.io/js/ethereumjs-blockstream.svg)](https://badge.fury.io/js/ethereumjs-blockstream) [![Build Status](https://travis-ci.org/ethereumjs/ethereumjs-blockstream.svg?branch=master)](https://travis-ci.org/ethereumjs/ethereumjs-blockstream) | ||
# Usage | ||
[Instantiate](https://github.com/ethereumjs/ethereumjs-blockstream/blob/master/tests/index.ts#L466): `new BlockAndLogStreamer(getBlockByHashFunction, getLogsFunction, { blockRetention: 5 });` | ||
[Subscribe](https://github.com/ethereumjs/ethereumjs-blockstream/blob/master/tests/index.ts#L467-L470): `blockAndLogStreamer.subscribeToOnLogAdded(onLogAddedCallback);` | ||
[Reconcile New Blocks](https://github.com/ethereumjs/ethereumjs-blockstream/blob/master/tests/index.ts#L512-L514): `blockAndLogStreamer.reconcileNewBlock(blockFromGetLatest);` | ||
# Build | ||
@@ -7,0 +14,0 @@ `docker build -t blockstream .` |
Sorry, the diff of this file is not supported yet
101510
56
1366
19