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
Describe the bug
The new version of js-xdr uses Buffer.subarray, but currently it does not work properly in pre-ES2016 environments. This has caused the new version of stellar-sdk to be unable to be used in React Native, because React Native uses the default JS engine that supports ES6.
To Reproduce
Steps to reproduce the behavior:
Run the following code in the ES6 engine, for example, Hermes, it is the default engine for React Native projects.
console.log(newXDR.Hyper(0).toXDR("base64"))
Actual output
0,0,0,0,0,0,0,0
Expected output
AAAAAAAAAAA=
Expected behavior
Works well in a pre-ES2016 environment. Additional context
N/A
The text was updated successfully, but these errors were encountered:
overcat
changed the title
XDR objects cannot be correctly converted to base64 strings in pre-ES2016 environments.
js-xdr cannot run in a pre-ES2016 environment.
Mar 8, 2024
overcat
changed the title
js-xdr cannot run in a pre-ES2016 environment.
js-xdr cannot works well in a pre-ES2016 environment.
Mar 8, 2024
Describe the bug
The new version of js-xdr uses
Buffer.subarray
, but currently it does not work properly in pre-ES2016 environments. This has caused the new version ofstellar-sdk
to be unable to be used in React Native, because React Native uses the default JS engine that supports ES6.I suggest reading this thread to learn more information: feross/buffer#329 (comment)
What version are you on?
3.1.0
To Reproduce
Steps to reproduce the behavior:
Run the following code in the ES6 engine, for example, Hermes, it is the default engine for React Native projects.
Actual output
Expected output
Expected behavior
Works well in a pre-ES2016 environment.
Additional context
N/A
The text was updated successfully, but these errors were encountered: