Skip to content

Instantly share code, notes, and snippets.

// SPDX-License-Identifier: GNU GPL v.3
pragma solidity ^0.6.2;
// Imports symbols from other files into the current contract.
// In this case, a series of helper contracts from OpenZeppelin.
// Learn more: https://solidity.readthedocs.io/en/v0.6.2/layout-of-source-files.html#importing-other-source-files
// IERC721 is the ERC721 interface that we'll use to make CryptoPizza ERC721 compliant
// More about ERC721: https://eips.ethereum.org/EIPS/eip-721
import "@openzeppelin/contracts/token/ERC721/IERC721.sol";
// SPDX-License-Identifier: GNU GPL v.3
pragma solidity ^0.6.2;
// Imports symbols from other files into the current contract.
// In this case, a series of helper contracts from OpenZeppelin.
// Learn more: https://solidity.readthedocs.io/en/v0.6.2/layout-of-source-files.html#importing-other-source-files
// IERC721 is the ERC721 interface that we'll use to make CryptoPizza ERC721 compliant
// More about ERC721: https://eips.ethereum.org/EIPS/eip-721
import "@openzeppelin/contracts/token/ERC721/IERC721.sol";
import { motion } from 'framer-motion'
import React, { useState, useEffect } from 'react'
import styled from 'styled-components'
export default function Cards(props) {
const [bar, setBar] = useState(false)
const { custom, src } = props
const Box = styled(motion.div)`
margin-top: 40px;
import React, { useState, useEffect } from 'react'
import '../App.css'
import 'bootstrap/dist/css/bootstrap.min.css'
import { Nav } from 'react-bootstrap'
import { motion } from 'framer-motion'
import { render } from '@testing-library/react'
import styled from 'styled-components'
function debounce(fn, ms) {
let timer
import React, { useState, useEffect } from 'react'
import '../App.css'
import 'bootstrap/dist/css/bootstrap.min.css'
import { Nav } from 'react-bootstrap'
import { motion } from 'framer-motion'
function debounce(fn, ms) {
let timer
return (_) => {
clearTimeout(timer)
[]
[]
[]
[]
[]
[]
[]
[]
[]
[]
import React, {
createContext,
useContext,
useReducer,
useMemo,
useCallback,
useEffect,
} from "react";
import { useWeb3React } from "@web3-react/core";
document.getElementById("count").onclick = function () {
incrementor();
};
function incrementor() {
let counterValue = 0;
let counter = document.getElementById("num");
counterValue += 1;
console.log("increment", counterValue);
counter.textContent = counterValue;
import React, { useState, useEffect } from "react";
import { StyleSheet, View, Text, RefreshControl } from "react-native";
import Timeline from "react-native-timeline-flatlist";
import { db, auth } from "../api/FirebaseApi";
export default function Transactions() {
const [contents, setContent] = useState("");
const [user, currentuser] = useState("");
const [refresh, setRefresh] = useState(false);
const [seed, setSeed] = useState(1);
import React from "react";
import { InputGroup, FormControl, Form, Button, Modal } from "react-bootstrap";
import Wallet from "./modal/Wallet";
import "./modal/Modal.css";
class Swap extends React.Component {
constructor(props) {
super(props);
this.state = {