Use unified NFT image URLs
Closed this issue · 0 comments
PopcornPaws commented
Description
Since all auctioned NFTs on the site have an associated image, we are storing URLs to these images on-chain and the webapp queries these URLs to show the image pertaining to the NFT. Currently, however, any kind of URL can be added as the NFT image.
Solution
We are setting this URL upon creating a master edition NFT. This master edition should store an URL of the form some-unified-url/0.jpg
with 0.jpg
denoting the master edition image. Then, the child editions can be uploaded as some-unified-url/1.jpg
, etc. Thus, the javascript contract logic can read only the master edition URL and replace the 0
with the current child edition number.