A blockchain lending application prototype with Node.JS and Truffle for the backend and React for the front-end. The centralised prototype and decentralised side are separated and work on different servers.
- Start your local MySQL server.
- Run the SQL commands from within the file
create-db.sql
(eiher via Terminal or the PhpMyAdmin interface) from the root directory, in order to create the database and to write some test data in it. - Clone the CryptoCredit repository.
- Install the dependencies both in the root directory and in the client directory with the command
npm install
. - To start the Node.JS server and the React application, run from the root directory:
npm run dev
. - To start the Truffle development server, run from the root directory:
npm run truffle
. - To start the decentralised side of the front-end application, run from the root directory:
npm run eth
.
The Node.JS server runs at: http://localhost:5000/.
The React front-end runs at: http://localhost:3000/.
The decentralised front-end with the integration to the smart contract runs at: http://localhost:8000/.
To interact with the dapp, copy and paste one of the addresses generated by the Truffle server into the field ‘Sender ETH address’. Submit any amount and interact with the dapp using the other buttons.