yarn add depay-decentralized-exchanges
or
npm install --save depay-decentralized-exchanges
import { DEX } from 'depay-decentralized-exchanges'
DEX.all
// [
// { name: 'uniswap_v3', label: 'Uniswap v3', logo: '...' }
// { name: 'pancakeswap_v2', label: 'PancakeSwap v2', logo: '...' }
// ...
// ]
DEX.findByName('uniswap_v3')
// { name: 'uniswap_v3', label: 'Uniswap v3', logo: '...' }
This library supports the following decentralized exchanges:
Decentralized exchange data is provided in the following structure:
{
name: String,
alternativeNames: Array,
label: String,
logo: String (base64 encoded PNG)
}
import { DEX } from 'depay-decentralized-exchanges'
DEX.all
// [
// { name: 'uniswap_v3', label: 'Uniswap v3', logo: '...' }
// { name: 'pancakeswap_v2', label: 'PancakeSwap v2', logo: '...' }
// ...
// ]
import { DEX } from 'depay-decentralized-exchanges'
DEX.findByName('uniswap_v3')
// { name: 'uniswap_v3', label: 'Uniswap v3', logo: '...' }
DEX.findByName('pancakeswap_v2')
// { name: 'pancakeswap_v2', label: 'PancakeSwap v2', logo: '...' }
yarn install
yarn start
npm publish