This file contains hidden or 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 hre from 'hardhat'; | |
| console.log('after hre'); | |
| import { DeploymentManager } from '../plugins/deployment_manager/DeploymentManager'; | |
| import { exp, fastForward } from '../test/helpers'; | |
| import { impersonateAddress } from '../plugins/scenario/utils'; | |
| import { setNextBaseFeeToZero } from '../scenario/utils/hreUtils'; | |
| import { getConfigurationStruct } from '../src/deploy'; | |
| console.log('after hre'); |
This file contains hidden or 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
| console.log('before hre'); | |
| import hre from 'hardhat'; | |
| console.log('after hre'); | |
| import { DeploymentManager } from '../plugins/deployment_manager/DeploymentManager'; | |
| import { sourceTokens } from '../plugins/scenario/utils/TokenSourcer'; | |
| import { exp, fastForward } from '../test/helpers'; | |
| import { impersonateAddress } from '../plugins/scenario/utils'; |
This file contains hidden or 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
| const { Contract, utils } = require('ethers'); | |
| const ethers = require('ethers'); | |
| const compABI = require('./comp-abi.json'); | |
| async function timeJump() { | |
| async function getBlock(n, provider) { | |
| const blockNumber = n == undefined ? await provider.getBlockNumber() : n; | |
| return provider.getBlock(blockNumber); | |
| } | |
This file contains hidden or 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
| const ethers = require('ethers'); | |
| const governorABI = require('./governor-abi.json'); | |
| async function castVote() { | |
| // First, we need to connect to the Ethereum network | |
| // https://ethforks.io/fork/aed9fe4c-6918-4dc5-88ba-9b1062aaf701' | |
| const provider = new ethers.providers.JsonRpcProvider('http://127.0.0.1:8545', { | |
| chainId: 1, | |
| }); |
This file contains hidden or 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
| query GetHubSellPage( | |
| $sellerInputUUID: String | |
| $customerUUID: String | |
| $addressUUID: String | |
| ) { | |
| seller { | |
| getLatestLead( | |
| input: { addressUuid: $addressUUID, customerUuid: $customerUUID } | |
| ) { | |
| lead { |
This file contains hidden or 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
| { | |
| "printWidth": 100, | |
| "trailingComma": "all", | |
| "tabWidth": 2, | |
| "semi": true, | |
| "singleQuote": true | |
| } |
This file contains hidden or 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
| /** | |
| * @param {string} a | |
| * @param {string} b | |
| * @return {string} | |
| */ | |
| var addBinary = function(a, b) { | |
| let i = a.length - 1, j = b.length - 1 | |
| let res = '' | |
| let carry = 0 | |
| while (i >= 0 || j >= 0) { |
This file contains hidden or 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
| <svg width="639" height="205" xmlns="http://www.w3.org/2000/svg"> | |
| <style> | |
| .lefty { | |
| animation: 1.25s ease-out 0s infinite fall-fade-left; | |
| } | |
| .righty { | |
| animation: 1.25s ease-out .10s infinite fall-fade-right; | |
| } |
This file contains hidden or 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
| <div id="root"></div> |
This file contains hidden or 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
| <h1>Progress bar</h1> | |
| <h2>Javascript using SetInterval to increment the element's width</h2> | |
| <div class="meter cadetblue"> | |
| <span data-progress="100" style="width:0;"></span> | |
| </div> | |
| <div class="meter"> | |
| <span data-progress="35" style="width:0;"></span> | |
| </div> |
NewerOlder