Skip to content

Instantly share code, notes, and snippets.

View schmidsi's full-sized avatar
🔬
Tinkering

Simon Emanuel Schmid | ses.eth schmidsi

🔬
Tinkering
View GitHub Profile
@schmidsi
schmidsi / JSON.sol
Created January 16, 2022 08:54
Example how to create a JSON from solidity
function makeJSON() public view virtual returns (string memory) {
return
string(
abi.encodePacked(
"data:application/json;base64,",
Base64.encode(
abi.encodePacked(
'{"name": "Bla #',
tokenId.toString(),
import { gql, useQuery } from '@apollo/client';
import { useWeb3React } from '@web3-react/core';
import { useEffect, useState } from 'react';
import { useAppContext } from '../components/AppContextWrapper';
const wait = (ms) => new Promise((resolve) => setTimeout(resolve, ms));
export const useLastMints = () => {
const [eventHandlerBound, setEventHandlerBound] = useState(false);
const { library } = useWeb3React();