https://github.com/vinodnextcoder/simple-dapp-typescript
This is a basic CRUD decentralized blockchain application in typescript
https://github.com/vinodnextcoder/simple-dapp-typescript
blockchain dapp ethereum ethereum-address ethereum-blockchain ethereum-contract ethereum-dapp ethereumjs simple-dapp-typescript solidity solidity-contracts solidity-dapps solidity-ethereum solidity-examples type-application typescript-blockchain-dapp typescript-dapp web3 web3-dapp web3js
Last synced: 4 months ago
JSON representation
This is a basic CRUD decentralized blockchain application in typescript
- Host: GitHub
- URL: https://github.com/vinodnextcoder/simple-dapp-typescript
- Owner: vinodnextcoder
- License: mit
- Created: 2022-07-16T13:11:18.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2022-07-17T05:09:00.000Z (almost 3 years ago)
- Last Synced: 2024-12-29T05:12:08.355Z (5 months ago)
- Topics: blockchain, dapp, ethereum, ethereum-address, ethereum-blockchain, ethereum-contract, ethereum-dapp, ethereumjs, simple-dapp-typescript, solidity, solidity-contracts, solidity-dapps, solidity-ethereum, solidity-examples, type-application, typescript-blockchain-dapp, typescript-dapp, web3, web3-dapp, web3js
- Language: TypeScript
- Homepage:
- Size: 104 KB
- Stars: 1
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Dapp in typescript
**A Create Your First dAPP On ethereum**#### AUTHOR:
- [Vinod](https://github.com/vinodnextcoder "vinods's github profile")
#### DESCRIPTION:
This repository contains a source code to create simple CURD application and smart contract code.#### Setup
- Follow this [Simple blockchain dapp vinod's blog](https://dev.to/vinodnextcoder/create-your-first-simple-dapp-on-ethereum-55k1) to create a decentralized application.# Introduction
```ts
In this article, we are going to build a simple CRUD decentralized application on theEthereum blockchain. Also will create a CRUD smart contract for the sameapplications. This is a practical hands-on article.Details process https://medium.com/geekculture/create-your-first-dapp-on-ethereum-6eb50b4083f2
- 1.Basic understanding of solidity or general programming.
- 2.Metamask extension on chrome or firefox. (To connect withweb3)
- 3.Basic understanding of Web3.
- 4. Wallet on metamask with some ether(coins) for a ropsten network.
- 5. Nodejs or javascript understanding.```
## Smart Contract Deployment
```
This is a simple curd smart contract, which deals with students’ data.
create copy .env.example to .env file
Let’s deploy the contract in a remix environment
First, navigate to address https://remix.ethereum.org/
Add new curd.sol
file and copy-paste the code from the repository.
From the left side click on the 3rd button deployment window will appear of metamask
```# Setup Steps
```
Smart contract deployment on ropsten network
First, create an account on https://infura.io get infra key
Testing of a smart contract.
The architecture of a decentralized application.
Build the decentralized application (dAPP) to interact with the blockchain.
Run and test the application
get abi and contract address from https://remix.ethereum.org/Run commands nodejs
```
## Installation
```
npm install
```## Run
```
Step-1
npx ts-node src/index.ts
###################################
Insert Record uncomment this linse
obj.createStudent('Vinod','MSc');
comment
obj.readStudent(0);
Step- ooutput
{
from: '0x8aeaexxxxxxxxxxxxxxxxxxxxxx',
gasUsed: 101374,
logs: [],
logsBloom: '0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000',
status: true, to: '0x83977bf3e9xxxxxxxxxxxxxxxx', transactionHash: '0x37169068b6606193XXXXXXXXXXXXXXXXXXXXX',
transactionIndex: 25,
type: '0x0'
}----------------------------------------------------------
Step-2 Reading record
npx ts-node src/index.ts
###################################
To read record
// comment this line in the index file
---->> obj.createStudent('Vinod','MSc');
// uncomment this lin
obj.readStudent(0);```
## License
MIT License