Categories
Cryptocurrency Ethereum Mastering Development

the best way to monitor my own account transactions in openethereum

Please I want to know if I subscribe to pendingTransactions with web3 will it monitor and send notifications of accounts pending Transactions only or all pending transactions on Ethereum network. my project requires users to create Ethereum address now I need to monitor incoming transaction of each user address to complete their services var Web3 […]

Categories
Cryptocurrency Ethereum Mastering Development

Web3js events and their callback functions are not aware of component state?

I have problem with web3js 1.2.9 Events triggering works fine and data is alright but I cannot figure out how to use component state in this functions that are triggered by event. I cannot access state of that component where watch event is initialized. this.state.contract.events.NewUserCreated() .on("connected",function (subscriptionId) {console.log("SubscriptionId ",subscriptionId)}) .on("data",function (event) { console.log("Event ",event) console.log("Current […]