Skip to content

A simple DApp to interact with a counter contract listen events and log to PostgreSQL

License

Notifications You must be signed in to change notification settings

pradeepp88/DApp-Counter-Contract

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Counter-Contract-with-Listen

Application Folder - app
Frontend created using - React and Truffle Drizzle - app/client
Backend created using - Node, Express and Postgres (with Event Listener and call reset) - app/node-postgres
Deployed and tested in local develop network created with Truffle

To deploy smart contract

cd app truffle develop compile migrate test

To start Frontend - Create a new instance

Disable MetaMask Wallet before starting the app
cd app/client npm start

PostgreSQL Settings

Change app/node-posgres/db.js file

To start backend

Change the contractAddress = 0x9c94B4fa4770ce4Ef8517994AB1EEa3Fb0BF963C line in index.js with the deployed contract address from truffle
cd app/node-postgres nodemon index.js

Test cases for contract

image

Screenshots

image

Reset Function called after count reaches 10 image

About

A simple DApp to interact with a counter contract listen events and log to PostgreSQL

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published