Question | STORM |
---|---|
Is the token tied to a product usage, i.e. does it give the user exclusive access to it, or provide interaction rights to the product? | Yes, 'Makers' are required to pay for posts in STORM tokens |
Does the token grant a governance action, like voting on a consensus related or other decision-making factor? | No |
Does the token enable the user to contribute to a value-adding action for the network or market that is being built? | Yes. Bolts can be used to boost Players access to tasks. |
Does the token grant an ownership of sorts, whether it is real or a proxy to a value? | No |
Does the token result in a monetizable reward based on an action by the user (active work)? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Example showing how to find a swap for a pair using SOR directly | |
* - Path only uses swaps: use queryBatchSwap on Vault to see result | |
* - Path use join/exit: Use SDK functions to build calls to submit tx via Relayer | |
*/ | |
import dotenv from 'dotenv'; | |
import { BigNumber, parseFixed } from '@ethersproject/bignumber'; | |
import { Wallet } from '@ethersproject/wallet'; | |
import { AddressZero } from '@ethersproject/constants'; | |
import { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Example using Etherscan API to analyse contract gas usage over time period. | |
// And .env file with ETHERSCAN API key. Free key from: https://etherscan.io/myapikey. | |
require('dotenv').config(); | |
const moment = require('moment'); | |
const axios = require('axios').default; | |
const Decimal = require('decimal.js'); | |
export const BONE = new Decimal(10).pow(18); | |
// Returns all transactions for block range |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Example showing how to get tx info from tx hash using ethers.js | |
// Add .env file with INFURA key. Free key from: https://infura.io/ | |
require('dotenv').config(); | |
import { JsonRpcProvider } from '@ethersproject/providers'; | |
import { Interface } from '@ethersproject/abi'; | |
async function getTransactionDetails(){ | |
let txHash = `0x4b55c0b756dbfbcd997e94b98698241299d16d5297cd17aa463d280d215a1f52`; // Example tx hash from Etherscan |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// npm add @ethersproject/abi | |
import { Interface } from '@ethersproject/abi'; | |
function transactionParsing(){ | |
console.log(`transactionParsing`); | |
const proxyArtifact = require('./abi/ExchangeProxy.json'); // See below | |
const iface = new Interface(proxyArtifact.abi); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require('dotenv').config(); | |
var moment = require('moment'); | |
const axios = require('axios').default; | |
const Decimal = require('decimal.js'); | |
export const BONE = new Decimal(10).pow(18); | |
// Returns all transactions for block range | |
export async function fetchTransactions(startBlock, endBlock) { | |
const proxyAddr = `0x6317C5e82A06E1d8bf200d21F4510Ac2c038AC81`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
I was doing this using the Klaytn network which is basically a centralised Ethereum clone. | |
The following code would work on Ethereum with a bit of a change - i.e. Caver to Web3 | |
*/ | |
/* | |
Example contract artificat addition: | |
"networks": { | |
"8217": { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var LeaderToken = artifacts.require("LeaderToken"); | |
var UniSwapFactory = artifacts.require("uniswap_factory"); | |
var UniSwapExchange = artifacts.require("uniswap_exchange"); | |
contract("UniSwapFactory", accounts => { | |
it("Add Liquidity.", async () => { | |
var UniSwapFactoryInstance = await UniSwapFactory.deployed(); | |
var LeaderTokenInstance = await LeaderToken.deployed(); | |
var ExchangeInstance = await UniSwapExchange.deployed(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
const Box = require('3box'); | |
class App extends React.Component { | |
constructor(props) { | |
super(props); | |
this.state = { | |
heading: 'What If I Told You', // Default values to display when no 3Box user settings loaded |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
const Box = require('3box'); | |
class App extends React.Component { | |
constructor(props) { | |
super(props); | |
this.state = { | |
heading: 'What If I Told You', |
NewerOlder