/** * A custom React hook for managing persistent state stored on a server. * * @template T - The type of the state to be persisted. * @param {T} defaultState - The initial state to use if no persisted state is found. * @returns {Object} - An object containing: * - `key` (string | null): The current key identifying the persisted state on the server. * - `state` (T): The current persisted state value. * - `expiresAt` (number): The expiration time of the state (timestamp). * - `setPersistentState` (function): A function to update the state on the server and locally. * - `error` (string | null): The error message, if any. * - `clearError` (function): A function to clear the error state. */ export declare const usePersistentState: (defaultState: T) => { key: string | null; state: T; expiresAt: number; setPersistentState: (newState: T) => Promise; error: string | null; clearError: () => void; };