You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When calling ethers.Wallet.createRandom() in react native the ui freezes probavly because the calculations are done in the main thread. how can we solve that ?
React native version
"react-native": "^0.72.4",
Code Snippet
No response
Contract ABI
No response
Errors
No response
Environment
No response
Environment (Other)
No response
The text was updated successfully, but these errors were encountered:
There are features added in v6 specifically to address this by shimming out the JavaScript functions for native implementations. I plan to get a package up that makes all these shims available, but any help would be appreciates.
For example, the expensive part of .createRandom() is likely the sha2-512 operation, so you can use: ethers.sha512.register((data) => { return nativeImplementation(data); } where nativeImplementation is a function you provide that calls a JNI (or such) implementation.
Ethers Version
6.8.1
Search Terms
No response
Describe the Problem
When calling ethers.Wallet.createRandom() in react native the ui freezes probavly because the calculations are done in the main thread. how can we solve that ?
React native version
Code Snippet
No response
Contract ABI
No response
Errors
No response
Environment
No response
Environment (Other)
No response
The text was updated successfully, but these errors were encountered: