Skip to content

Latest commit

 

History

History
33 lines (32 loc) · 954 Bytes

contract-flow.md

File metadata and controls

33 lines (32 loc) · 954 Bytes

User Flow

flowchart TD
    A[Start] --> B[deployAcrossChains]
    B --> C[Compute expected address using CREATE2]
    C --> D{For each target chain}
    D --> E[Encode payload: bytecode + salt]
    E --> F[Calculate deployment cost]
    F --> G[Send payload to Wormhole Relayer]
    G --> H[Wormhole Core Contract]
    H --> I[Wormhole Guardian Network]
    I --> J[Wormhole Core Contract on target chain]
    J --> K[Wormhole Relayer on target chain]
    K --> L[Call receiveWormholeMessages]
    L --> M[Decode payload]
    M --> N[Deploy contract using CREATE2]
    N --> P[Emit ContractDeployed event]
    P --> Q{More chains?}
    Q -->|Yes| D
    Q -->|No| S{Deploy on current chain?}
    S -->|Yes| T[Deploy contract using CREATE2]
    T --> U[Verify deployed address matches expected]
    U --> V[Emit ContractDeployed event]
    V --> R[End]
    S -->|No| R[End]
    subgraph Wormhole Components
    H
    I
    J
    K
    end
Loading