TVM-Solidity-Compiler icon indicating copy to clipboard operation
TVM-Solidity-Compiler copied to clipboard

Make generator json for solidity

Open user090909 opened this issue 2 years ago • 1 comments

Hello. I have a problem with generating json objects onchain. For example with tip4_2 we can change json on chain but for now its a bit hard _json = '{"type": "Basic Nft", "name": "Opened nft lootbox","preview": {"source":"' + format("{}",_img.link) +'","mimetype":"' + format("{}", _img.mimetype) + '"}}'; we need to do such constructions where we can easily put a mistake. Probably, json generators like in python could help with this problems?

user090909 avatar Jun 21 '22 07:06 user090909

https://gist.github.com/user090909/51bf389ae1914bee0e59b342216d5a4e

user090909 avatar Jun 22 '22 16:06 user090909

@user090909 Thanks for the issue. Currently we don't plan to build JSON serialization into the language's capabilities yet, but you can still easily implement such a serializer by following the information at www.json.org

cryshado avatar Mar 23 '23 17:03 cryshado