@akala/core
Version:
19 lines (18 loc) • 728 B
TypeScript
/**
* Symbol to identify proxy instances
* @type {Symbol}
*/
export declare const isProxy: unique symbol;
/**
* Node.js inspect symbol for custom object display
* @type {Symbol}
*/
export declare const customInspect: unique symbol;
/**
* Creates a method-chaining proxy for functions
* @template T - Target function type
* @param {T} target - Function to wrap with proxy
* @param {(keys: string[], ...args: unknown[]) => unknown[]} keyHandler - Callback to process keys and arguments
* @returns {Proxy<T>} - Proxied function supporting chained method calls
*/
export declare function chain<T extends (...args: unknown[]) => unknown>(target: T, keyHandler: (keys: PropertyKey[], ...args: unknown[]) => unknown[]): T;