Adding "mempool block" details. Work in progress!

This commit is contained in:
softsimon
2020-03-17 21:53:20 +07:00
parent f147c7259d
commit aca1b20772
18 changed files with 260 additions and 9 deletions

View File

@@ -62,6 +62,7 @@ class MempoolBlocks {
blockSize: blockSize,
blockVSize: blockVSize,
nTx: transactions.length,
totalFees: transactions.reduce((acc, cur) => acc + cur.fee, 0),
medianFee: this.median(transactions.map((tx) => tx.feePerVsize)),
feeRange: this.getFeesInRange(transactions, rangeLength),
};

View File

@@ -12,6 +12,7 @@ export interface MempoolBlock {
blockVSize: number;
nTx: number;
medianFee: number;
totalFees: number;
feeRange: number[];
}