compile.js :  const path = require('path'); const solc = require('solc'); const fs = require('fs-extra');  const buildPath = path.resolve(__dirname, 'build'); fs.removeSync(buildPath);  const campaignPath = path.resolv...
I'm working with React, Next.Js, semantic-ui-react and Solidity. It is my goal to print out the users address (from MetaMask) and a ProjectTitle (set by User) as meta infomation for a semantic-ui-react card. To print out the address in the 'h...
Is there any way to auto-generate test-cases in Truffle?  As an example, the AutoFixture Library was helping me to auto-generate test-cases in xUnit. I'm looking for a similar functionality....
Anyone know why my parameter is being seemingly ignored when I run the dapp?   This function is called when I press the button to send an X amount of money to a ganache account who's address I input into an HTML form while using the dapp.      Ap...
totalSupply = initialSupply * 10 ** uint256(decimals);    If the initialSupply = 21000000.000000000000000000  (21 million) Why multiply by 10?  pragma solidity ^0.4.16;  contract owned {     address public owner;      function owned() public {...
I am trying to set a spinner while my react app makes a few calls. I am writing a Dapp with web3 and solidity. While making calls to my smart contract I try to set state to show a spinner, but the whole app freezes while the calls to the contract are...
I am learning on how to create a voting app with truffle and rendering on the screen everything goes well. So now I don't want to use vanilla js but want to add a framework to it, called knockout.js  I tried it in everyway but for some reason the...
//Contract build .json to js obj import { abi } from './contract.js'  //Init web3 import { getWeb3 } from  './getWeb3'  // Import are working fine.  export const getTokenContract = () => (   new Promise((resolve, reject) => {...
This is the solidity code that I am trying. Compiling of the code works fine. However, when I call the function send() via javascript it throws exception : throw new Error('invalid address');  pragma solidity ^0.4.6;  contract Agreement {...
There is a code for a simple conversion (Farenheit to Celcius) in HTML. I am working to recreate the same thing in Solidity. I would need some pointers in making it work. The solidity Code is as follows:   contract TemperatureSolution{     uint16 inp...

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.