Git Product home page Git Product logo

dapp's Introduction

Liquid Democracy as a smart contract

๐Ÿšจ๐Ÿšง Everything in this repo is still a work in progress and higly experimental. It is not secure to use any of this code in production (mainnet) until proper security audits have been conducted.

This is a smart contract implementation (dapp) in the Ethereum blockchain of a liquid democracy with three initial main functionalities: vote(), delegate() and revoke(). It mainly consists of LiquidDemocracy.sol and its corresponding test file LiquidDemocracy.test.js. This is the starting point of a roadmap that seeks to bridge Sovereign app with blockchain features. Please make sure you check out the project board and the milestones for more information.

The most recent version of the dapp is available at http://dapp.democracy.earth. For desktop usage, you will need Metamask and a Metamask-supported browser to be able to interact with it. For mobile usage, use a dapp browser / wallet like Toshi.

Contributing

PRs and feedback are welcomed. A good place to start is to review the current open issues, please feel free to engage with us by commenting in a specific issue. Remember you can also check out the project board to understand what's being worked on now and what is coming up next.

Dapp development is discussed actively in the slack channel #developers in democracyearth.slack.com

The dapp consists of mailnly two elements, contracts and frontend, located respectively in the following folders:

  • contracts: Solidity contracts, to be deployed to a local or remote blockchain.
  • dApp-Srv-Exp: JS frontend built using npm, bower and http-server

Development dependencies

How to run

Compile, deploy and copy compiled contracts to frontend

Choose the environment. Use development for local environment (start ganache before) or ropsten for Ropsten Ethereum test network in remote environment.

$ npm install
$ truffle compile
$ truffle migrate --network [development / ropsten]
$ cp build/contracts/* dApp-Svr-Exp/contracts/

Start frontend

$ npm start

Access

You will be able to access the dapp at http://localhost:8080 in development mode. Make sure to set Metamask to the right environment (private network or Ropsten), and also make sure to provision necessary gas for each case:

Local environment

Import private keys from Ganache into Metamask (Accounts -> Import account)

Remote environment

Use a Ropsten faucet. e.g.: http://faucet.ropsten.be:3001/

dapp's People

Contributors

aecc avatar alexjupiter avatar lucasisasmendi avatar medied avatar santisiri avatar shubhamtatvamasi avatar virgile-dev avatar xalava avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.