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
/* | |
* Arconnect docs: https://arconnect.io/ | |
* arweave.js docs: https://github.com/ArweaveTeam/arweave-js | |
* Arweave developer docs: https://docs.arweave.org/developers/ | |
*/ | |
import Arweave from 'arweave'; | |
const arweave = Arweave.init({ | |
// host: 'arweave.net' |
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
# Build locally | |
# docker build . -t myvscodeapp | |
# Run locally | |
# docker run -it -p 3000:3000 myvscodeapp | |
FROM gitpod/openvscode-server:latest | |
USER root | |
ENV NODE_VERSION=14.18.0 | |
RUN apt-get update |
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
/* | |
* this file includes both a node.js script for creating a keypair | |
* as well as the client code for using it | |
*/ | |
/* createKeypair.js */ | |
const fs = require('fs') | |
const anchor = require("@project-serum/anchor"); | |
const web3 = require('@solana/web3.js') | |
const account = anchor.web3.Keypair.generate(); |
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 './App.css'; | |
import { useEffect, useState } from 'react'; | |
import { | |
Program, | |
Provider, | |
BN, | |
web3, | |
} from '@project-serum/anchor' | |
import { | |
Connection, |
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 './App.css'; | |
import { useEffect } from 'react'; | |
import { | |
Program, | |
Provider, | |
BN, | |
web3, | |
} from '@project-serum/anchor' | |
import { | |
Connection, |
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 './App.css'; | |
import { useState } from 'react' | |
import CeramicClient from '@ceramicnetwork/http-client' | |
import ThreeIdResolver from '@ceramicnetwork/3id-did-resolver' | |
import { EthereumAuthProvider, ThreeIdConnect } from '@3id/connect' | |
import { DID } from 'dids' | |
import { IDX } from '@ceramicstudio/idx' |
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 './App.css'; | |
import { createClient } from 'urql' | |
import { useEffect, useState } from 'react' | |
const APIURL = "" | |
const query = ` | |
query { | |
tokens( | |
first: 5 |
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
/* pages/creator-dashboard.js */ | |
import { ethers } from 'ethers' | |
import { useEffect, useState } from 'react' | |
import axios from 'axios' | |
import Web3Modal from "web3modal" | |
import { | |
nftmarketaddress, nftaddress | |
} from '../config' |
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
*/ pages/my-assets.js */ | |
import { ethers } from 'ethers' | |
import { useEffect, useState } from 'react' | |
import axios from 'axios' | |
import Web3Modal from "web3modal" | |
import { | |
nftmarketaddress, nftaddress | |
} from '../config' |
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
/* pages/create-item.js */ | |
import { useState } from 'react' | |
import { ethers } from 'ethers' | |
import { create as ipfsHttpClient } from 'ipfs-http-client' | |
import { useRouter } from 'next/router' | |
import Web3Modal from 'web3modal' | |
const client = ipfsHttpClient('https://ipfs.infura.io:5001/api/v0') | |
import { |