0.0.9 • Published 4 years ago

@akroma-project/akroma-erc20-token-list v0.0.9

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
4 years ago

@akroma-project/akroma-erc20-token-list

List of all ERC20 tokens on the Akroma Network (akroma.org). This library is forked from ethereum-lists/src/tokens/eth/

How to use

const { getTokenInfo } = require('@akroma-project/akroma-erc20-token-list');

console.info(getTokenInfo('Dumb'));
import { getTokenInfo } from '@akroma-project/akroma-erc20-token-list';

console.info(getTokenInfo('Dumb'));

API Manual

There is only one API in this library:

/**
 * Get the token info.
 *
 * @param symbol The token symbol, e.g., USDT, BNB, LINK, etc.
 * @returns The TokenInfo, undefined if not exists
 */
export declare function getTokenInfo(symbol: string): TokenInfo;

Which returns an TokenInfo:

export interface TokenInfo {
  address: string;
  decimals: number;
  ens_address: string;
  logo: Logo;
  name: string;
  social: Social;
  support: Support;
  symbol: string;
  type: string;
  website: string;
}

export interface Logo {
  height: string;
  ipfs_hash: string;
  src: string;
  width: string;
}

export interface Social {
  blog: string;
  chat: string;
  facebook: string;
  forum: string;
  github: string;
  gitter: string;
  instagram: string;
  linkedin: string;
  reddit: string;
  slack: string;
  telegram: string;
  twitter: string;
  youtube: string;
}

export interface Support {
  email: string;
  url: string;
}

Quick Start

npx @akroma-project/akroma-erc20-token-list Dumb

Pushing to NPM

npm publish --access public
0.0.9

4 years ago

0.0.8

4 years ago

0.0.7

4 years ago

0.0.6

4 years ago

0.0.5

4 years ago

0.0.4

4 years ago

0.0.3

4 years ago