Go to file
2023-04-07 17:26:35 +08:00
docs docs: update README 2023-02-26 03:13:12 +08:00
public feat: use bootstrap template 2023-02-25 22:51:46 +08:00
src feat: management page 2023-04-07 17:26:35 +08:00
.gitignore feat: init vue.js project 2023-02-25 21:34:18 +08:00
index.html feat: management page 2023-04-07 17:26:35 +08:00
package-lock.json feat: management page 2023-04-07 17:26:35 +08:00
package.json feat: management page 2023-04-07 17:26:35 +08:00
README.md fix: change to Sepolia Test Network 2023-03-15 17:27:36 +08:00
vite.config.js feat: init vue.js project 2023-02-25 21:34:18 +08:00

Faucet Webpage

A simple webpage for Sepolia Testnet's faucet.

It's HW1 for 1112 NCNU CSIE "Principles and Practice of Blockchains"

link to Metamask and create a transaction to the smart contract to get SepoliaETH.

Project Setup

npm install

fill in your smart contract's address

// /src/views/FaucetView.vue line 46
    const transactionParameters = {
        from: ethereum.selectedAddress,
        to: '',               // smart contract's address
        data: encodeFunctionCall,
        value: '0x00',
    }

Compile and Hot-Reload for Development

npm run dev

Compile and Minify for Production

npm run build

Notice

Now, I am not sure of difference between window.ethereum & web3

I use window.ethereum to send transaction, check accounts, check network and use web3 to encode ABI.

I am not sure whether it's a suitable implementation