Allow Scripts to "Borrow" Resources by ID
Issue To Be Solved
It's hard for scripts to access the information in Resources if they don't know where they are stored. Often, a Resource's ID is known, but its storage location is not.
Suggested Solution
Allow scripts (and only scripts) to borrow a reference to Resource objects by ID, regardless of where they are stored. This would allow a script to get access to the data about a resource without having to know where it is.
Note: there is a proposed feature of the new NFT standard that would enable loading of metadata for any NFT via its ID. The problem with this is that it encourages metadata storage in the contract instead of in the NFT, which is not aligned with the "resource mindset".
@j1010001 metadata has to be stored in the contract actually. (i am not sure if any contract store in the resource)
@dete this is great feature, but it is too tricky , basically flow-go has to be resource aware. Ofc can make ugly solutions here (cadence alerting flow-go when resource saved, moved etc)
This is dream come true
Would really love to see this.
wrote a forum post about storage fees ( softly touching this topic ) https://forum.onflow.org/t/storage-fees-improvements-and-few-random-ideas-on-the-way/5104