interface UseUpvotedListOptions

Passed to useUpvotedList by useUserDumpFeed, for an upvoted list.

Properties

profileUserId: string | null

The list holds this user's upvotes. It is null while their profile loads.

setItems: (fn: (prev: Dump[]) => Dump[]) => void

Does nothing until the list is loaded.

optional
source: Dump[]

It holds dumps already at hand, which a vote of the signed-in user on their own list puts first at once, before the socket's vote event. The profile passes its first page of the user's dumps.

Usage

import { type UseUpvotedListOptions } from "src/hooks/dump/useUpvotedList.ts";