https://github.com/bitfancy/nft-smart-contract
https://github.com/bitfancy/nft-smart-contract
Last synced: 11 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/bitfancy/nft-smart-contract
- Owner: BitFancy
- License: mit
- Created: 2024-02-19T19:15:52.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-02-19T19:21:48.000Z (about 2 years ago)
- Last Synced: 2025-02-15T20:54:19.012Z (about 1 year ago)
- Language: JavaScript
- Size: 320 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Develop Smart Contract for NFT Marketplace
[](https://github.com/your-username/mastering-state-management/blob/main/LICENSE)
Welcome to the repository for the project code of the online project [Develop Smart Contract for NFT Marketplace](https://educat.tv/3HcT7Gu).
This project is built on the Ethereum blockchain that enables users to mint, list, and trade non-fungible tokens (NFTs). The smart contract is written in **Solidity**, utilizing the **ERC721** token standard for unique token identification.
We’ll utilize the **Hardhat** framework to develop the smart contract. By using this technology, we can easily develop, test, and deploy the contracts. We’ll also use **OpenZeppelin**, a widely recognized library of reusable and secure smart contract components in our project.
The key features that this project will contain are as follows:
- **Minting:** Users can create and mint new NFTs by providing a token URI and setting an initial price for the NFT.
- **Listing:** NFTs can be listed for sale at a specified price. A listing fee is required for listing an NFT on the marketplace.
- **Buying:** Users can purchase listed NFTs by sending the required payment, transferring the ownership of the NFT to the buyer, and providing the necessary fees to the contract owner.
- **Retrieving:** Users can retrieve a list of all NFTs available on the marketplace and view their personal collection of NFTs.
## Installation
To get started with the course project code, follow these steps:
1. Clone this repository to your local machine using the following command:
```shell
git clone https://github.com/snsakib/develop-smart-contract-for-nft-marketplace.git
```
2. Change to the project directory:
```shell
cd develop-smart-contract-for-nft-marketplace
```
3. Install the dependencies using npm or yarn:
```shell
npm install
```
or
```shell
yarn install
```
4. To run the unit test file, open a terminal and run the following command:
```shell
npx hardhat test
```
5. Open a new terminal and run the following command to start the local Hardhat node:
```shell
npx hardhat node --hostname 0.0.0.0 --port 3000
```
6. Open another terminal and run the following command to deploy the smart contract on the local Hardhat node:
```shell
npx hardhat run scripts/deploy.js --network localhost
```