so I would like to deploy an EOS contract using eosjs. I encountered several problems (especially with converting the .abi and .wasm files). All the examples either use node (so fs is available) or an older version of eosjs. I tried to use fetch and save the files as byte arrays, but I don't know how to convert them to the right format. While searching, I found: https://cmichel.io/setcode-and-setabi-with-eos-js/ and https://github.com/EOSIO/eosjs/issues/285, but neither of these threads helped me with deploying a contract directly from the browser (as they all talk about using node and thus are capable of reading the files directly from the system). Has anyone done something similar and could provide some guidance (code snippet with an example)? I am actually a little bit baffled that this is currently so inconvenient, as deploying a contract should be a pretty common use case.

Thanks in advance and kind regards, Simon

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.