Poll: A Decentralized Poll Application (DApp)

After 2 weeks of studying BlockChain and different DApps, it was time for me to try and build a simple DApp. I teamed up with a colleague, @markusveeyola , who is also studying BlockChain and we build a poll system.

DApps란?



Decentralized Applications (DApps) are applications built using the BlockChain technology. For more information on Blockchain, please see this link: htps : // b ぉ CK 게다가 ks. 이 m / gue s / u-t-s-b-ck chan-ch ch-gy /

There are lots of DApps availalabe online. However, there are common features between this application. Here are the features:

오픈 소스 (Open Source)
It should be handled by autonomy. You need a consensus to change the application.

분산형(Decentralized)
It is necessary to store the application data in a social distributed BlockChain. This is to avoid central power.

인센티브화(Incentivized)
Rewards should be given to the BlockChain's validator.

프로토콜(Protocol)
The community must agree to a cryptographic algorithm that indicates proof of value.

Poll이란?



A poll is a survey in which people are asked about their opinion by choosing a category/candidate on a certain topic. This is done to find out how popular something is or what people wants.

우리 폴 시스템이란?



Our DApp lets the user create a poll and its candidates. The creator can also add a title, description, and the end-date for the poll. Then, other users can vote the candidate they want to. Elections and group decisions can be conducted through our system. Decisions such as what food to eat, where to travel, and class president election.

사용되는 Tools



To make the system, we used React.js, Web3.js, Solidity and Github. We placed all our data in the BlockChain via Solidity. We did the front-end of our web application using React.js. Then connect React.js. and Solidity using Web3.js. We stored our code in a repository in Github. During development, we struggled the most in using Web3.js because we encountered a lot of errors. Also, there was no complete documentation about Web3.js so resolving the errors was very hard.

For more information about React.js, Web3.js, Solidity, and Github, please see the links below:
React.js : htps : // Rea ctjs. rg/
Web3.js : htps // 우우 b3js. Red d. cs. 이오/엔/1.0/
Solidity : htps : // ぃぢ ty. Red d. cs. 이오/엔/v0.4.25/
Github : htps : // 기주 b. 코 m / 후 아츠레 s

Application의 Screenshot



Here are the screenshots of our application. It's a simple application that only has 2 pages.

You can view our code from GitHub in this link: htps : // 기주 b. 코 m / ゔ 센 세미 라 / Pop lSys mBC

Create Poll





The Create Poll page is just a simple form. The creator needs to input the name and description of the poll, and when it will end. Users can also search for a poll using the search form in the header.

Poll details 과 Vote Candidate





The Poll contains the name and description of the poll, and the start and end date of the poll. The creator of the poll can add a candidate using the add form. Users can view the candidates and see the progress of the poll. They can also vote for their favorite candidate.

요약



This test was very fun and we learn a lot. We learned how to use React.js and Web3.js. We learned how to deploy the Solidity Contract to Web3 using the Remix IDE. It was also our first time to use Github so this project is the first project in our repository. The best thing that we learned was that there are a lot of problems on building a Dapp, so thinking and looking for a solution is very important.

좋은 웹페이지 즐겨찾기