Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/starcoinorg/starcoin-poll
Poll Dapp for the Starcoin DAO
https://github.com/starcoinorg/starcoin-poll
blockchain dao dapp governance react starcoin
Last synced: 25 days ago
JSON representation
Poll Dapp for the Starcoin DAO
- Host: GitHub
- URL: https://github.com/starcoinorg/starcoin-poll
- Owner: starcoinorg
- License: apache-2.0
- Created: 2021-06-14T13:57:05.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2023-02-23T05:12:48.000Z (almost 2 years ago)
- Last Synced: 2024-11-08T02:46:51.457Z (3 months ago)
- Topics: blockchain, dao, dapp, governance, react, starcoin
- Language: TypeScript
- Homepage: https://poll.starcoin.org
- Size: 1.05 MB
- Stars: 1
- Watchers: 11
- Forks: 2
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## Version dependency in development
`$node -v`\
v10.12.0`$npm -v`\
6.4.1`$tsc -v`\
Version 4.1.3`$yarn -v`\
1.22.10`$npx -v`\
6.4.1`$npx create-react-app starcoin-poll --template typescript`
## Set Environment Variables
```
export REACT_APP_STARCOIN_NETWORKS=main,barnard,halley,proxima
export REACT_APP_STARCOIN_POLL_API_URL=https://poll-api.starcoin.org
export REACT_APP_STARCOIN_POLL_ADMIN_ADDRESS=0x...
```
`REACT_APP_STARCOIN_POLL_ADMIN_ADDRESS` is the address that can create polls.## How to run
> check for updates first if needed
>
>`$git clone [email protected]:starcoinorg/starcoin-poll.git`\
>`$cd starcoin-poll`\
>`$yarn``$yarn start`
Runs the app in the development mode.\
Open [http://localhost:3008](http://localhost:3008) to view it in the browser.The page will reload if you make edits.\
You will also see any lint errors in the console.## How to test
`$yarn test`
Launches the test runner in the interactive watch mode.
## How to test deploying
Build the app for production to the `build` folder:
`$yarn build`
Your app is ready to be deployed!
You may want to serve it locally with a static server for test before deploying:
```
npm install -g serve
serve -s build
```Then visit: [http://localhost:5000](http://localhost:5000)
## How to publish
1. use aws cli to upload the files to AWS S3 Bucket:
`$aws s3 cp ./build s3://poll.starcoin.org/ --recursive`
2. use shell to build and upload files to AWS S3 Bucket:
`./publish.sh`
> PS: use proxy to speed up
## How to CI/CD
```
$git tag vx.y.z
$git push --tag
```A github action will be triggered and deploy the newest version.