Skip to content

[Frontend] Implement the poolsStore #140

Description

@Muhammadcodes112

Description

Holds fetched pool listings and the current filter/pagination UI state for the browse page.

Where

astre_frontend/src/store/poolsStore.ts (new file)

What to implement

A Zustand store with state { pools: Pool[]; total: number; page: number; isLoading: boolean; search: string } and actions setPools(data), setLoading(bool), setSearch(term), setPage(n). Define and export a Pool TypeScript type matching the shape the backend's GET /pools returns (see the backend's Pool entity issue for the field list — omit backend-only fields like the internal id if you want, but contractPoolId, title, description, goal, raised, status should match).

Acceptance Criteria

  • Store exists with the state/actions above
  • Pool type is exported and used by the store's pools field
  • npm run typecheck passes

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    frontendNext.js app (astre_frontend)good first issueGood for newcomersphase-1Core donation-loop MVP (1/3 scope), builds on mvp-phase-1 branch

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions