xrpl.js icon indicating copy to clipboard operation
xrpl.js copied to clipboard

Methods to convert currency name to currency code

Open tequdev opened this issue 2 years ago • 5 comments

It would be nice to have a util method to convert currency name with more than 4 digits into currency code.

tequdev avatar Jan 11 '23 15:01 tequdev

By "currency code", do you mean the 40-character hexadecimal string?

intelliot avatar Jan 12 '23 00:01 intelliot

Yes.

The 4-digit currency code (SOLO) is represented as a 40-char HEX value and it would be useful to have these parsers.

HEX values are also used outside of common currency codes, so that would need to be taken into account (e.g. AMM's LP Token).

tequdev avatar Jan 19 '23 06:01 tequdev

https://github.com/Transia-RnD/xrpl-helpers/blob/main/ts/src/index.ts

dangell7 avatar Jan 24 '23 00:01 dangell7

can i work on this issue?

Rishabh-1126 avatar Jan 10 '24 04:01 Rishabh-1126

can i work on this issue?

Yes

ckniffen avatar Jan 10 '24 05:01 ckniffen