xrpl-accountlib icon indicating copy to clipboard operation
xrpl-accountlib copied to clipboard

Not available in Vite environment

Open tequdev opened this issue 1 year ago • 6 comments

The package published or the dependency contains process code and will not work in the vite environment. スクリーンショット 2024-08-08 21 24 56

https://vitejs.dev/guide/env-and-mode

tequdev avatar Aug 08 '24 12:08 tequdev

It seems to be caused by assert() used in [email protected]. In 2.0.0, the assert package is no longer used.

tequdev avatar Aug 08 '24 12:08 tequdev

@tequdev I'll dive in later, but for now: could it make sense to simply polyfill node process? E.g. with vite-plugin-node-polyfills

WietseWind avatar Aug 09 '24 06:08 WietseWind

I thought it would be more beneficial to the user if this package itself could solve this problem, rather than all users of this package in a vite environment using that plugin.

If you decide not to take this action, I will respect your decision.

tequdev avatar Aug 09 '24 06:08 tequdev

Oh I plan to take action, I was just trying to give a temp workaround for until I fix this at package level, since I'm currently on a holiday ;)

WietseWind avatar Aug 09 '24 06:08 WietseWind

No hurry! Thanks.

tequdev avatar Aug 09 '24 06:08 tequdev

@tequdev I just updated ripple-keypairs in this lib and the dependency libs (xrpl-sign-... and secret numbers lib):

[email protected]

WietseWind avatar Aug 22 '24 08:08 WietseWind