These examples demonstrate the main features of alloy and alloy-core as well as how to use them.
To run an example, use the command cargo run --example <Example>
:
cargo run --example mnemonic_signer
This repository contains the following examples:
- Anvil
- Big numbers
- Contracts
- Fillers (Middleware)
- Layers
- Primitives
- Subscriptions
- Providers
- Queries
-
sol!
macro - Transactions
- Decode input
- Encode and decode EIP-1559 transaction
- Get gas price in USD
- Trace call
- Trace transaction
- Transfer ERC20 token
- Transfer ETH
- Sign and send a raw transaction
- Send EIP-1559 transaction
- Send legacy transaction
- Send EIP-4844 transaction
- Send private transaction using Flashbots Protect
- Send transaction with access list
- Wallets
Thanks for your help improving the project! We are so happy to have you! We have a contributing guide to help you get involved in the Alloy project.
Pull requests will not be merged unless CI passes, so please ensure that your contribution follows the linting rules and passes clippy.
Licensed under either of Apache License, Version 2.0 or MIT license at your option.Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in these crates by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.