Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
bokkypoobah committed Apr 27, 2024
1 parent 10ffddf commit 77b74cd
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion docs/online.html
Original file line number Diff line number Diff line change
Expand Up @@ -1028,7 +1028,14 @@
async processNewBlock(blockNumber) {
const provider = new ethers.providers.Web3Provider(window.ethereum);
this.feeData = await provider.getFeeData();
console.log(moment().format("HH:mm:ss") + " processNewBlock[" + this.chainId + "] #" + this.commify0(blockNumber) + ", latest #" + this.commify0(this.blockNumber) + " @ " + moment.unix(this.timestamp).format("YYYY-MM-DD HH:mm:ss") + " " + moment.unix(this.timestamp).fromNow() + " " + JSON.stringify(this.feeData, bigNumberReplacer, 2));
console.log(moment().format("HH:mm:ss") + " processNewBlock[" + this.chainId + "] #" + this.commify0(blockNumber) +
", latest #" + this.commify0(this.blockNumber) +
" @ " + moment.unix(this.timestamp).format("YYYY-MM-DD HH:mm:ss") +
" " + moment.unix(this.timestamp).fromNow() +
"\n\tgasPrice: " + ethers.utils.formatUnits(this.feeData.gasPrice, "gwei") + " gwei " +
"\n\tlast to max Base + priority feePerGas: " + ethers.utils.formatUnits(this.feeData.lastBaseFeePerGas, "gwei") +
" to " + ethers.utils.formatUnits(this.feeData.maxFeePerGas, "gwei") +
" + " + ethers.utils.formatUnits(this.feeData.maxPriorityFeePerGas, "gwei") + " gwei ");
},
async halt() {
this.sync.halt = true;
Expand Down

0 comments on commit 77b74cd

Please sign in to comment.