Skip to content

Instantly share code, notes, and snippets.

@matrix-compute
Forked from WietseWind/index.js
Created November 24, 2023 15:23
Show Gist options
  • Save matrix-compute/4ab756d1550a5f2140e4d030fbbf1f74 to your computer and use it in GitHub Desktop.
Save matrix-compute/4ab756d1550a5f2140e4d030fbbf1f74 to your computer and use it in GitHub Desktop.
Encode/Decode X-address in the browser (plain HTML+JS)
<script src="https://xrpaddress.info/js/xrpl-tagged-address-codec-browser.js"></script>
<script>
var XCodec = require('xrpl-tagged-address-codec')
console.log(XCodec.Encode({ account: 'rPEPPER7kfTD9w2To4CQk6UCfuHM9c6GDY', tag: 495 }))
console.log(XCodec.Decode('XV5sbjUmgPpvXv4ixFWZ5ptAYZ6PD28Sq49uo34VyjnmK5H'))
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment