6 releases
new 0.3.3 | Oct 2, 2024 |
---|---|
0.3.2 | Sep 30, 2024 |
0.2.12 | Sep 18, 2024 |
#464 in Magic Beans
15,659 downloads per month
Used in 5 crates
(3 directly)
84KB
1.5K
SLoC
op-alloy-genesis
Genesis types for Optimism.
Usage
By default, op-alloy-genesis
enables both std
and serde
features.
If you're working in a no_std
environment (like kona
), disable default features like so.
[dependencies]
op-alloy-genesis = { version = "x.y.z", default-features = false, features = ["serde"] }
Rollup Config
op-alloy-genesis
exports a RollupConfig
, the primary genesis type for Optimism Consensus.
There are a few constant declarations for various chain's rollup configs.
use op_alloy_genesis::{OP_MAINNET_CONFIG, rollup_config_from_chain_id};
let op_mainnet_config = rollup_config_from_chain_id(10).expect("infallible");
assert_eq!(OP_MAINNET_CONFIG, op_mainnet_config);
Provenance
This is based off of alloy-genesis.
Dependencies
~9MB
~178K SLoC