"Token-curated registries are decentrally-curated lists with intrinsic economic incentives for token holders to curate the list's contents judiciously" - Mike Goldin
TCRs use an intrinsic token to incentivize a community to reach decentralized consensus and curate a registry of high-quality entries
NOTICE: commands prefixed with $
should be executed in this repo, while commands prefixed with >
should be executed in a separate shell, in a cloned tcr repo
TCR-UI:
Clone & run app in dev mode in browser, rebuild on file changes - localhost:3000
$ git clone https://github.com/kangarang/tcr-ui.git
$ cd tcr-ui
$ npm install
$ npm run dev
Tests
Run unit tests with Jest
$ npm test
Local blockchain/RPC (optional):
ganache-cli - localhost:8545
$ npm run rpc
Warning: Do not use the mnemonic associated with this command on ethereum main network. You will lose your funds!
TCR (optional):
Clone & install/compile smart contracts
> git clone https://github.com/kangarang/tcr.git
> cd tcr
> npm install
> npm run compile
Deploy contracts (optional):
local test network
> npm run deploy-ganache
rinkeby test network
> npm run deploy-rinkeby
tcr-ui retrieves ABIs from IPFS, then loads the tcr smart contracts using the current networkID
of MetaMask. the ABIs retrieved from IPFS are the same ABIs as the ones located in /scripts/abis/
The registry MUST be deployed to a network. If you have a registry address that you want to force, hardcode it in /src/config/registry.json
If you do not want to rely on hardcoding the address, you can add a custom set of ABIs to IPFS:
- Edit the
"address"
of the appropriate"networks"
section of /scripts/abis/Registry.json - Run
npm run update:abis
to add your custom abis to IPFS. (note: a multihash starting with "Qm" will be printed) - Update the
ipfsABIsHash
variable in /src/redux/libs/ipfs.js to the IPFS multihash
|
├── docs - Documentation
├── public - Files that don't get compiled, just moved to build
| └── index.html - Html template file
├── scripts
| └── abis - TCR contract JSON ABIs
├── src
| ├── config - Config data
| ├── redux - Redux-related
| | ├── libs - Framework-agnostic libraries
| | ├── modules - Redux modules
| | | ├── [module] - Single Redux module
| | | | ├── sagas - Asynchronous side-effects
| | | | ├── tests - Jest unit tests
| | | | ├── actions.js - Action creators / plain objects
| | | | ├── index.js - Duck root import / export
| | | | ├── reducers.js - Pure functions / immutable.js
| | | | ├── selectors.js - State selectors / reselect.js
| | | | ├── types.js - Action types / string constants
| | | | └── utils.js - Module-specific helpers
| | | ├── index.js - Ducks root
| | | └── reducers - Reducer combiner
| | ├── utils - Common utility helper functions
| | ├── store.js - Redux reducer and middleware injector
| ├── views - React
| | ├── assets - Images, fonts, etc.
| | ├── components - Stateless, dumb components
| | ├── containers - Stateful, smart containers
| | ├── translations - Language JSON dictionaries
| | ├── App.js - Root React component
| | └── global-styles.js - Theme / colors
| └── index.js - Entry point for app
└── server.js - Express.js app
Articles
- Token-Curated Registries 1.0
- Token-Curated Registry 1.1, 2.0
- Continuous Token-Curated Registries: The Infinity of Lists
- City Walls & Bo-Taoshi: Exploring the Power of Token-Curated Registries
Code
Community
These workflow diagrams were created by our wonderful designer, Eva Shon
This project is licensed under the MIT license, Copyright (c) 2018 Isaac Kang. For more information see LICENSE
.