Context: in the zeke/contracts-v1 branch the cw-core contract has a concept of an item. An item is a mapping between String and Addr. I think we should change this to a map between String and cosmwasm_std::Binary.
The initial idea is that this would primarily point towards sub contracts. The trouble with this is that if we want to store simple state in a DAO for the UI (ex. a code of conduct) we need to write a code of conduct contract that just stores a string. This is extra work + slow for the UI because it requires two queries (1. address of contract 2. code of conduct).
Binary will be nice because it means we can store pretty much whatever we want there (binary is base64 encoded 'stuff'). If we want to put an addr in there we can decide standards on the frontend. For example, we could make everything JSON under the hood.
Context: in the
zeke/contracts-v1
branch thecw-core
contract has a concept of an item. An item is a mapping betweenString
andAddr
. I think we should change this to a map betweenString
andcosmwasm_std::Binary
.The initial idea is that this would primarily point towards sub contracts. The trouble with this is that if we want to store simple state in a DAO for the UI (ex. a code of conduct) we need to write a code of conduct contract that just stores a string. This is extra work + slow for the UI because it requires two queries (1. address of contract 2. code of conduct).
Binary will be nice because it means we can store pretty much whatever we want there (binary is base64 encoded 'stuff'). If we want to put an addr in there we can decide standards on the frontend. For example, we could make everything JSON under the hood.