Skip to content

Commit

Permalink
Merge pull request #109 from coinbase/eric/chain-support
Browse files Browse the repository at this point in the history
Features: Networks
  • Loading branch information
ilikesymmetry authored Dec 16, 2024
2 parents afb7cf2 + 95a0d74 commit 53d452e
Show file tree
Hide file tree
Showing 4 changed files with 49 additions and 16 deletions.
15 changes: 0 additions & 15 deletions docs/pages/FAQ.mdx
Original file line number Diff line number Diff line change
@@ -1,18 +1,3 @@
## What networks are supported?
- Base
- Arbitrum
- Optimism
- Zora
- Polygon
- BNB
- Avalanche
- ETH mainnet (not preferred for use, due to gas cost)

**Testnets**
- Sepolia
- Base Sepolia
- Optimism Sepolia

## How does Smart Wallet work with Coinbase Wallet mobile app and extension?
For now, Smart Wallet is separate from wallet mobile and extension. Users sign on [keys.coinbase.com](https://keys.coinbase.com/)
and can view and manage assets at [wallet.coinbase.com](https://wallet.coinbase.com/).
Expand Down
2 changes: 2 additions & 0 deletions docs/pages/faq/why-does-it-cost-more-on-ethereum-l1.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ Due to these inherent costs, we strongly recommend using Layer 2 networks like:
- Optimism
- Arbitrum

See [Networks](/features/networks) for a complete list of supported networks.

Layer 2 solutions provide:
- Significantly lower transaction fees
- Same security guarantees
Expand Down
37 changes: 37 additions & 0 deletions docs/pages/features/networks.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# Networks

## Mainnet Networks
- Base
- Arbitrum
- Optimism
- Zora
- Polygon
- BNB
- Avalanche
- Ethereum mainnet ([not recommended due to costs](/faq/why-does-it-cost-more-on-ethereum-l1))

## Testnet Networks
- Sepolia
- Base Sepolia
- Optimism Sepolia

## Details

### Addresses across Networks
Users have the same Smart Wallet address across supported networks.

### Deployment
- Smart Wallets are deployed using the "counterfactual deployment" pattern
- The wallet contract is deployed on first transaction
- Same address is reserved across all chains through CREATE2
- Deployment costs are included in the first transaction

### `initCode`
- `initCode` determines the wallet's address
- Contains factory address and initialization parameters
- Ensures consistent address across all chains
- Used by bundlers to deploy the wallet if needed

### tx.origin Behavior
- `tx.origin` will be the bundler EOA address, not the Smart Wallet address
- Consider this when integrating with existing contracts
11 changes: 10 additions & 1 deletion vocs.config.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,16 @@ export default defineConfig({
text: "Base Gasless Campaign",
link: "/base-gasless-campaign",
},
{
text: "Features",
collapsed: false,
items: [
{
text: "Networks",
link: "/features/networks",
},
],
},
{
text: "Guides",
collapsed: false,
Expand Down Expand Up @@ -146,7 +156,6 @@ export default defineConfig({
},
{
text: "MagicSpend Support",

link: "/guides/magic-spend",
},
{
Expand Down

0 comments on commit 53d452e

Please sign in to comment.