Open HosseinAsadi opened 2 years ago
Does eth.chainChanged
not work either?
:(
nop
if(eth != null) eth!.chainChanged.listen((event) { showSnackBar(event.toString()); });
generally How can I call a custom event?
This is for listening metamask events: In dart_wrappers.dart file replace:
Stream
With this or whatever you like as long as you cast the stream, for sure there are other better ways to acomplish this matter, but the problem seems to be on casting issues
Stream
On the other hand, Event API in metamask tell us that "chainchanged" should be returned a String instead of "int"
Stream
I'm testing the package in order to use metamask in web, desktop and android with the same library using other providers.
When I send a transaction to a contract it would be nice nonce field was autocalculated instead always call "getTransactionCount" on the signer(credentials)
Hi
I need to listen some event into my dApp project
Inside your suggested document, listen to each event as follows
final eth = window.ethereum; if (eth != null) eth!.stream('chainChanged').listen((event) { showSnackBar(event.toString()); });
but this does not work at all
do you have any suggestion for me?