Distributed Application Starter: Vue front-end, Ethereum / IPFS Backend
Distributed Application Starter: Vue front-end, Ethereum / IPFS Backend
Distributed Application Starter: Vue front-end, Ethereum / IPFS Backend
Ethereum is a distributed virtual machine that pays eth in return for miners running your smart contracts. IPFS is a kind of distributed content distribution network. Vue is a javascript framework for building client-side webapps. By keeping state inside ethereum and using IPFS to deliver HTML, webapps can become nearly indestructible!
Install IPFS: https://ipfs.io/docs/install/
Install the MetaMask Ethereum wallet (and register an account): https://metamask.io/
Install: npm i -g ganache-cli (local Ethereum test network)
Install: npm i -g truffle (Solidity toolkit!)
To obtain your key: ipfs key list -l
Set: export IPFS_PUBKEY=QmQozMTQHW9g6fKmHerVHoKQNQo4zhfXQMsWMTuJ6D1sJd (Example key)
Run: ganache-cli --accounts=4
Select Localhost 8545 as your RPC form the MetaMask UI
Use the generated passphrase to log into MetaMask eg:
HD Wallet
==================
Mnemonic: shoe panic long movie sponsor clarify casino stable calm scene enforce federalImport the other accounts in to MetaMask for testing using the generated private key eg:
Private Keys
==================
(0) 2f3a3521d79a5e5c58972224d80a678c993a1a50b7cf8a2ee51e255e55fb041d {
try {
const newContract = await Contract.new(c.name, c.terms, {
from: c.witness,
gasPrice: 2000000000,
gas: '2000000'
})
return newContract
} catch (e) {
console.log(e, 'Error creating contract...')
}
}
export { createContractInstance }
Tested with:
Teach and learn JavaScript with us at RED Academy: https://redacademy.com/
No open issues yet, or sync has not completed.