go to  ForumEasy.com   
JavaPro
Home » Archive » Message


[Email To Friend][View in Live Context][prev topic « prev post | next post » next topic]
  Step 1: Install Packages
 
Subject: Step 1: Install Packages
Author: WebSpider
In response to: Smart Contract --II: Deploy via 3 Ways
Posted on: 06/07/2021 07:01:03 AM


npm install web3 --save
npm install dotenv --save
npm install truffle-hdwallet-provider --save


The package dotenv is used for storing your credentials like API_KEY or private keys

The package truffle-hdwallet-provider is used to connect your wallet to blockchain network


 

> On 06/07/2021 06:59:15 AM WebSpider wrote:


There are three ways to deploy a smart contract to Ethereum blockchain:

  • Way 1: Via Remix IDE with Built-In/Injected Web3 provider + MetaMask wallet
  • Way 2: Via Truffle Framework with HDWProvider + any wallet
  • Way 3. Via Web3js script with HDWProvider + any wallet

    Here, we use the 3rd way: Via Web3js script with HDWProvider + any wallet

    Prerequisites:
  • Node.js installed
  • Wallet to authenticate to Testnet or Mainnet to make transaction (including deploy)
  • A contract with abi and bytecode to be deployed




    References:

  •  


     
    Powered by ForumEasy © 2002-2022, All Rights Reserved. | Privacy Policy | Terms of Use
     
    Get your own forum today. It's easy and free.