chainlist •

Minimal no_std rust bindings for the Chainlist API built in pure Rust.
Getting Started
Add the chainlist crate to your project:
= "0.1.0"
Usage
use ;
// Get the RPC Configuration for Ethereum Mainnet.
let mainnet = CHAINS.iter.find.expect;
assert_eq!;
// Using the `rpc!` macro.
let mainnet = rpc!;
assert_eq!;
// Get the `Chain` RPC configuration from an alloy "NamedChain".
// Note, this will panic if an RPC configuration doesn't exist
// in the chain list for the given chain id.
let mainnet: Chain = Mainnet.into;
assert_eq!;
Safety
Warning
This is experimental software and is provided on an "as is" and "as available" basis. Expect rapid iteration and use at your own risk.