Skip to content

Commit

Permalink
feat: Add method to retrieve specific chain tokens by chainId
Browse files Browse the repository at this point in the history
  • Loading branch information
trungbach committed Nov 7, 2024
1 parent e97d018 commit 14176b9
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/common/src/token-items/token-items.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,10 @@ export class TokenItemsImpl implements TokenItems {
});
};

getSpecificChainTokens(chainId: string) {
return this.getTokensFromNetwork(this.chainInfos.find((chain) => chain.chainId === chainId));
}

get otherChainTokens() {
return flatten(
this.chainInfos
Expand Down

0 comments on commit 14176b9

Please sign in to comment.