Skip to Content
Ethereum Smart Contract Development
book

Ethereum Smart Contract Development

by Mayukh Mukhopadhyay
February 2018
Intermediate to advanced
288 pages
6h 58m
English
Packt Publishing
Content preview from Ethereum Smart Contract Development

Events

EVM logging facilities can be conveniently used by a smart contract via events. How is this done using events? Well, JavaScript comes to the rescue here. While developing DApps, the frontend is almost always a JavaScript page, mostly using Node.js or web3.js. These pages listen for events and, in turn, initiate JavaScript calls in the DApp's user interface.

When such event calls happen, they cause arguments to get stored in transaction logs. These logs are a special data structure in the blockchain and are associated with the address of the contract. These logs stay as long as a block is accessible. We cannot access the event or log data within a contract. This requires PoW. Events are inheritable and a great tool for debugging smart ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Building Games with Ethereum Smart Contracts: Intermediate Projects for Solidity Developers

Building Games with Ethereum Smart Contracts: Intermediate Projects for Solidity Developers

Kedar Iyer, Chris Dannen

Publisher Resources

ISBN: 9781788473040Supplemental Content