import { Trade } from 'moonbeamswap' import React, { Fragment, memo, useContext } from 'react' import { ChevronRight } from 'react-feather' import { Flex } from 'rebass' import { ThemeContext } from 'styled-components' import { TYPE } from '../../theme' import CurrencyLogo from '../CurrencyLogo' export default memo(function SwapRoute({ trade }: { trade: Trade }) { const theme = useContext(ThemeContext) return ( {trade.route.path.map((token, i, path) => { const isLastItem: boolean = i === path.length - 1 return ( {token.symbol} {isLastItem ? null : } ) })} ) })