Goal is to make an example that highlights the protocol capabilities of CUTB. We've already a bit of UI:
Now we're gonna need to sort through the program structure:
[x] WE ARE SOMEWHAT BLOCKED W/O PROGRAM COMPOSABILITY. We need a means to update the main program. We can achieve this by storing the main programs secret_key in an env var and then exposing an endpoint in the playground that will allow people to add their profile to the address map, but it's not as ideal as the outcome with composability.
[x] The program will need to have a main program that links all of the users together. Each user will list the main program as a linked program
[x] Each user when "signing up" will deploy a program from their wallet that will cite the main program as a linked program and store the user's data: username, imgUrl, bio. It will also need to add the post program as a linked program so a users post program can update the user's program with it's post metadata (programId, tokenId)
[x] Each user will then create a post program that will cite the user program as a linked program. The post program will be of non-fungible structure and the "mint" function will be a method that "mints" a new post to the user program. The post will need: timestamp, content, likeMap, commentMap
Goal is to make an example that highlights the protocol capabilities of CUTB. We've already a bit of UI:
Now we're gonna need to sort through the program structure:
username, imgUrl, bio
. It will also need to add the post program as a linked program so a users post program can update the user's program with it's post metadata (programId, tokenId)timestamp, content, likeMap, commentMap