| Crates.io | token-list |
| lib.rs | token-list |
| version | 0.7.0 |
| created_at | 2021-07-06 22:36:44.182523+00 |
| updated_at | 2025-03-04 00:53:31.109465+00 |
| description | Ethereum token list standard |
| homepage | |
| repository | https://github.com/telcoin/token-list.git |
| max_upload_size | |
| id | 419721 |
| size | 78,740 |
Ethereum token list standard created by Uniswap
Cargo.toml:
token-list = { version = "0.1.0", features = ["from-uri"] }
tokio = { version = "1", features = ["full"] }
main.rs:
use token_list::TokenList;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let token_list = TokenList::from_uri("https://defi.cmc.eth.link").await?;
assert_eq!(token_list.name, "CMC DeFi");
Ok(())
}
You don't need the tokio dependency if you do not wish to enable the from_uri method.