Ethereum Application

Тема в разделе "Блокчейн, криптотехнологии", создана пользователем suraj, 25 май 2020.

  1. suraj

    suraj новичок

    Another trick is to add proxy contracts, where each of them executes a particular function in your main contract upon receiving Ether. As a simple example, let's say you are implementing a binary voting application: you have your main contract with a vote-yes and a vote-no function. Rather than asking the user to include the yes-or-no flag in their transaction, you can deploy two additional contracts, with no logic except for calling vote-yes or vote-no in the main contract on behalf of the message sender upon receiving any transaction. Needless to say, this approach only works in rather simple apps, but can often help reduce complexity for users who do not have Ethereum-aware software in their browsers.