truncate-eth-address
TypeScript icon, indicating that this package has built-in type declarations

1.0.2 • Public • Published

truncate-eth-address

A very small and simple utility to truncate ethereum addresses to a more readable format. No dependencies.

Before: 0x7358B726830A2E222f9b139E90483A37142bcBE5 After: 0x7358…cBE5

Usage:

import truncateEthAddress from 'truncate-eth-address'

const walletAddress = `0x7358B726830A2E222f9b139E90483A37142bcBE5`
console.log(`Your address is: ${truncateEthAddress(walletAddress)}`)

/truncate-eth-address/

    Package Sidebar

    Install

    npm i truncate-eth-address

    Weekly Downloads

    1,388

    Version

    1.0.2

    License

    MIT

    Unpacked Size

    3.09 kB

    Total Files

    7

    Last publish

    Collaborators

    • greypixel_