@replyke/core
Version:
Replyke: Build interactive apps with social features like comments, votes, feeds, user lists, notifications, and more.
12 lines (11 loc) • 429 B
TypeScript
import { Entity } from "../../interfaces/models/Entity";
declare function useEntityVotes(props: {
entity: Entity | undefined | null;
setEntity: React.Dispatch<React.SetStateAction<Entity | undefined | null>>;
}): {
upvoteEntity: () => Promise<void>;
removeEntityUpvote: () => Promise<void>;
downvoteEntity: () => Promise<void>;
removeEntityDownvote: () => Promise<void>;
};
export default useEntityVotes;