3

Solidity's syntax has some similarities to JavaScript, and a large amount of tooling has been written in JavaScript. However, I would not say that knowledge of JavaScript is an absolute prerequisite. ethereum.org maintains a list of language specific resources that you may find useful: https://ethereum.org/developers/#language-specific-resources


2

I teach and develop courseware for B9lab. There is no absolute requirement for JavaScript knowledge and I would argue that similarities between Solidity and JavaScript are superficial. There is much to unlearn, in any case, because blockchain platforms are unlike any other form of software regardless of syntax. External to the blockchain there is always a ...


1

For that type of situations it is recommended to use a withdrawal pattern. You do not pay directly but instead you store the winning address, then the winner have to call a withdraw function and it will be able to retrieve the prize. function makePayment(string result) public { if (result.toSlice().equals("home".toSlice())) { winner = homeBet;...


1

I see you modified the question after several valid/correct answers: Question is: how to invoke GenNextID like a regular function, that is: call to this function mutates internal state it returns result returned from the contract's code YOU DON'T You either mutate the state and get a receipt, or you get a response but you don't mutate the ...


1

In your first example, you are trying to print result.blockNumber without verifying first that the result object is valid. In your second example, you are referring to the first input parameter of the callback function as if it was the result object, when it is in fact the error object. In short, try this: web3.eth.getTransaction('0x2fc3...', function(...


1

The answer to your first question seems to be quite straight forward: you need to provide a callback to the function. It is what the error tells you to do, moreover, the documentation says a callback can be added. Example web3.eth.sendTransaction(transaction, () => { // your callback })


1

See this tutorial and example in Status's documentation. https://status.im/developer_tools/run_on_status/eip-1102.html The idea is to maintain backward compatibility while also introducing and supporting EIP-1102 if/when the browser/metamask/etc supports it. In other words, add EIP-1102 without breaking existing provider support. It looks for EIP-1102 and ...


1

Hardened child keys are the ones using apostrophes (m/44'/60'/0'). By design, hardened child keys cannot be derived from extended public keys, only from private (xprv). To get around this, you derive the part that includes hardened children directly from your private key and leave the last non-hardened part of the path to be derived for each user. var ...


Only top voted, non community-wiki answers of a minimum length are eligible