Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/stephancill/portfolio-nft
On-chain NFT that allows users to track their crypto portfolio on a particular chain
https://github.com/stephancill/portfolio-nft
Last synced: 16 days ago
JSON representation
On-chain NFT that allows users to track their crypto portfolio on a particular chain
- Host: GitHub
- URL: https://github.com/stephancill/portfolio-nft
- Owner: stephancill
- Created: 2021-12-24T20:48:26.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2022-02-06T14:18:58.000Z (almost 3 years ago)
- Last Synced: 2024-05-16T11:17:46.715Z (6 months ago)
- Language: JavaScript
- Homepage:
- Size: 2.71 MB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-nft-onchain - Repository
README
# Portfolio NFT
Allows the minter to track their ERC-20 token balances and USD values in an on-chain SVG
without relying on any third parties.## Usage
```
yarn install
``````
npx hardhat test
```### Generate frontend ABIs
```
npx hardhat deploy --export-all ./client/src/contracts.json
```## Testing
```
npx hardhat test
```With external network forking:
```
FORK=polygon npx hardhat node --network hardhat
FORK=polygon npx hardhat --network localhost
```### Frontend debugging with local chain
1. Start node
```
FORK=mainnet npx hardhat node --network hardhat
```2. Export ABIs
```
FORK=mainnet npx hardhat deploy --export ./client/src/contracts.json --network localhost
```## Deployment
### Checklist
- [ ] Use Flashbots RPC to avoid paying for failed transactions
- [ ] Confirm WETH symbol in `deploy/00_portfolio_nft.js`
- [ ] Set correct name and symbol in `deploy/00_portfolio_nft.js`
- [ ] Remove `hardhat/console.sol` imports
- [ ] Verify contract on Etherscan
- [ ] Verify contract on Sourcify```
npx hardhat deploy --network
npx hardhat etherscan-verify --network
```