decent-sdk
Version:
SDK for the Decent API
19 lines (18 loc) • 799 B
TypeScript
import { SupportedChainId } from '../../core/types/Chains';
import { Proposal } from '../../core/types/Proposal';
import { Address } from '../../core/types/Common';
import { QueryReturn } from '../types';
type FetchProposalsParams = {
chainId?: SupportedChainId;
address?: Address;
};
/**
* React hook to fetch all proposals for a specific DAO.
*
* @param {FetchProposalsParams} params - Object containing chainId and address.
* @param {SupportedChainId} params.chainId - The EIP155 chain ID
* @param {Address} params.address - The contract address of the DAO
* @returns {QueryReturn<Proposal[]>} Object with { data: Proposal[], isLoading: boolean, error: Error | null }
*/
export declare const useFetchProposals: (params: FetchProposalsParams) => QueryReturn<Proposal[]>;
export {};