Skip to content

This is a smart contract tutorial, this tutorial guide you how to compile & deploy a mintable ERC20 token smart contract using client side signature & Web3 without truffle.

Notifications You must be signed in to change notification settings

onimusya/SolidityTutorial

Repository files navigation

Solidity Tutorial

1. Introduction

First goal of this tutorial is to compile & deploy a mintable ERC20 token smart contract using client side signature & Web3 without truffle. The ERC20 token contract is using Open Zeppelin Framework. It also has sample code to execute smart contract function by using sendRawTransaction().

Then the second part of this tutorial app is allow user to upload their profile photo to IPFS and the hash is stored in the Ethereum Blockchain. When the script detects there is a IPFS hash in the Blockchain, it will retrieve from IPFS and display it as user's profile photo.

Here is the demo site for the tutorial: Smart Contract Demo

2. Prerequisite

  • Node.js v8++
  • Npm v5.6++

3. Installation

  • npm install

4. Test the code

Please rename appconfig.sample.js to appconfig.js. All configuration settings are stored in appconfig.js.

4.1 Compile Solidity Code

node app.js --build

4.2 Deploy Smart Contract

node app.js --deploy

4.3 Read Properties from Token Contract

node app.js --contractinfo

4.4 Mint Token

node app.js --mint 10

5. A Cup of Coffee

If you think this tutorial sample help you, would like to buy me a cup of coffee, you can send eth to my wallet address 0xF68B84024Ab718A79B3eb4D53cCE7Ee2254F4241 as support.

About

This is a smart contract tutorial, this tutorial guide you how to compile & deploy a mintable ERC20 token smart contract using client side signature & Web3 without truffle.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published