Let's get started by installing the necessary dependencies:
If you intend to host your database locally, you will also require mongod, which is included in the MongoDB system (https://docs.mongodb.com/manual/installation/).
Also, if you don't already have Node.js, you can install it here (https://nodejs.org/en/download/).
The rest of the dependencies can be installed by running:
Open a terminal and run
Presently, there are three main schemas; one for the user credentials and information (credentials), another for storing the minimal information necessary for the block chain (blockchain), and one for storing block information (blockinfochain).
The corresponding servers can be started by opening terminals in src/backend and running nodemon credentialServer.js
,
nodemon blockServer.js
and nodemon blockInfoServer.js
, respectively.
Finally, run
to start the local development server (http://localhost:3000).
On the initial page, you can create an account, sign-in, or scroll down to learn about how the exchange works.
Scroll down, and you will see
Each account starts off with 2500 of paper currency, and users can deposit actual money to their account, which is handled through Stripe.
Navigate to the Create Block tab, and you can set-up a contract to your preference. This contract will be made available to other BlockXChnge users.
You'll notice the available contract appear on your Home page (see Home tab). This is where other users can click and decide whether to join your block.
Once the block is joined, you'll notice a new addition to the public block chain. The block's information (along with the previous block's hash) was hashed and is identifiable on the block chain via the block's summary.