Skip to content

Recuperacion de sesion y state restore #47

@Kalebtron1

Description

@Kalebtron1

Why this matters

Restoring session state reduces friction when wallets disconnect or users reload the page.

Problem

Session recovery is fragile and users can lose pending state or need to reconnect too often.

Scope

  • Persist the minimum state needed to restore the flow.
  • Rehydrate the user session and wallet state on reload.
  • Add a safe fallback when the stored state is stale.

Implementation guidance

  • Touch src/context/AppContext.tsx, src/hooks/useWallet.tsx, src/components/WalletSetupModal.tsx, and src/main.tsx.
  • Store only the data needed to restore the current flow.
  • Keep the recovery logic predictable and easy to debug.

Out of scope

  • A full account recovery system.
  • Persisting unnecessary user state.

Acceptance criteria

  • PR includes the recovery logic and the exact state that is persisted.
  • Reviewer can reproduce a reload and see the expected state restored.
  • The PR description explains how stale state is handled.

Validation

  • Run npm run dev and reload the page with an active wallet state.
  • Run npm run build to confirm the code still compiles.
  • Verify stale state is ignored or refreshed as documented.

PR requirements

  • Include Closes #47.
  • Document what is persisted and why.
  • Explain how the fallback path behaves.

Complexity

  • Medium (100 points)

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programcomplexity:medium150 points - standard feature touching multiple areasfrontendFrontend implementation workwalletWallet connection and signing flows

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions