Ganache — personal blockchain

Dapp development process is a little more complex than standard app building. It is all because of deploying some part of it to blockchain.

Ganache — personal blockchain

Dapp development process is a little more complex than standard app building. It is all because of deploying some part of it to blockchain.

Once it is deployed, changing it is impossible, only adding new smart contract which takes into account corrections to previous version can save a dApp.


Agenda:

  • intro,
  • what is ganache,
  • why is it needed,
  • conclusion.

What is ganache

According to official docs:

“Ganache is a personal blockchain for rapid Ethereum and Corda distributed application development.”

It means that you can use Ganache across the entire development cycle. It enables developing, deploying, and testing your dApps in a safe and deterministic environment.

Ganache is built as UI and CLI. Ganache UI supports ethereum and Corda technology as a desktop platform.


Command Line tool offers:

  • console.log in Solidity
  • Zero-config Mainnet and testnet forking
  • Fork any Ethereum network without waiting to sync
  • Ethereum JSON-RPC support
  • Snapshot/revert state
  • Mine blocks instantly, on demand, or at an interval
  • Fast-forward time
  • Impersonate any account (no private keys required!)
  • Listens for JSON-RPC 2.0 requests over HTTP/WebSockets
  • Programmatic use in Node.js
  • Pending Transactions

Link for official docs:

GitHub - trufflesuite/ganache: A tool for creating a local blockchain for fast Ethereum development.
Features * Getting Started * Documentation * Community * Docker * Contributing * Related Ganache is an Ethereum…

Why is it needed?

Generally, testing dapps does not require deploying smart contracts directly on the mainnet network and pay fees. It can be proceeded by pushing it to testnet.

However, it also takes time, even if it is free…

Ganache simulates blockchain on your machine, making testing super smooth and quick. You do not need to power up wallet with testnet coins to deploy smart contracts, it is automatically done. Moreover, network is much faster.


Conclusion

Ganache is a very efficient solution for building and testing dapps, smart contracts, etc. implementing it to a project can give a lot of benefits, such as:

  • speeding up the development process,
  • make testing easy,
  • all is for free.

Do you like this content, follow repo below to be updated with web3 threads 🧵

GitHub - Kacper-Hernacki/100-days-of-web3-challenge-blockchain-free-materials: This is the repo…
This is the repo which consists 100 topics about blockchain/ decentralisation/ web3. There are links to my articles,…