How to use the bsv.Address function in bsv

To help you get started, we’ve selected a few bsv examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github dfoderick / bitshovel / bitshovel.js View on Github external
function toCashAddress(originalAddress) {
    const a = new bsv.Address(originalAddress)
    const ac = a.toCashAddress()
    return ac.replace("bitcoincash:","")
}
function toOriginalAddress(cashAddress) {
github dfoderick / bitshovel / bitshovel.js View on Github external
function toOriginalAddress(cashAddress) {
    return (new bsv.Address(cashAddress)).toLegacyAddress()
}