ECMAScript Proxy Object

Proxy object is used to define custom behavior for fundamental operations (e.g. property lookup, assignment, enumeration, function invocation, etc). ================================================================handler: Placeholder object which contains traps. traps: The methods that provide property access. This is analogous to the concept of traps in operating systems. target: Object which the proxy virtualizes. It is often used as storage backend …

Draft.js

Draft.js is a framework for building rich text editors in React, powered by an immutable model and abstracting over cross-browser differences. Draft.js makes it easy to build any type of rich text input, whether you’re just looking to support a few inline text styles or building a complex text editor for composing long-form articles. https://draftjs.org/

React – Prevent Render when Props and State change

When we change the state or props of the component, render method is called by default. In order to prevent this behavior, we can use shouldComponentUpdate method. If we return false from this method, render is not called. This method receives props and state as parameter so we can check if certain state or props …

Bignumber issue in web3 invalid number value

Getting invalid number error when calling a method of a contract which take uint256 argument. Example:myContract.methods.transfer(accounts[1], 1e16).send({ from: accounts[0] }) When sending value 1e16 it throw errorweb3 invalid number value (arg=”_value”, coderType=”uint256″, value=10000000000000000) When sending value 10000000000000000 throw same error When sending value 1e16 as hex it work okay. No error. When sending value 1e15 …