NFTs are one of the foundations of web3. This series will introduce NFTs through 30 short articles, allowing everyone to understand and master the relevant knowledge about NFTs from scratch.
In previous articles, we discussed how NFTs need to be minted for the first time. In this article, we will delve into the principles behind it.
Minting, or "铸造" in Chinese, refers to the interaction between users and NFT smart contracts to generate NFTs. The minting action only occurs when an NFT is generated for the first time.
Next, let's take a detailed look at what happens during the minting process.
First, let's understand what a smart contract is. Simply put, it is executable code stored on the blockchain. In general, each smart contract can implement certain functions.
Minting is the process where users interact with NFT smart contracts to generate a brand new NFT.
To ensure compatibility among products on Ethereum, there is an official set of standards. There are two standards related to generating NFTs: ERC-721 and ERC-1155. These two standards can be used to create NFTs. (To learn more about ERC, you can click here, but we will focus on these two standards.)
NFTs generated by ERC-721 are unique, while those generated by ERC-1155 can be unique or non-unique. In other words, NFTs generated by ERC-721 are non-fungible, while those generated by ERC-1155 can be either fungible or non-fungible, depending on the developer's decision.
Although ERC-1155 offers more flexibility, current data shows that ERC-721 is more widely adopted. This may be because early well-known NFTs were built on the 721 standard, which has greater user acceptance and more projects. Using a more mature standard can reduce the cost of user education for projects and avoid potential risks of using a new standard.
When the code for an NFT project is completed and deployed on the chain, the questions of when, how, and by whom to mint these NFTs are controlled by people. During the minting process, the project owner can mint some or all of the NFTs, or users can mint them themselves. It is worth mentioning that if users mint the NFTs themselves, they can set the mint price in advance in the code.
In summary, we now know that minting is the process of interacting between people and smart contracts to generate NFTs. For an NFT, it is only "minted" when it is generated as an NFT by a smart contract for the first time. Buying NFTs in the marketplace or receiving NFTs from others does not involve the "minting" process. To make a comparison with a printed artwork, minting is the action of printing a pattern on a blank paper, and once completed, the artwork will enter the market.