export type TimerId = number | NodeJS.Timeout;
export interface ManagedResource {
    type: 'timer' | 'interval' | 'animationFrame' | 'eventListener' | 'domElement' | 'observable' | 'reactRoot';
    id: string | TimerId;
    cleanup: () => void;
    metadata?: Record<string, any>;
}
export declare class ResourceManager {
    private resources;
    private globalResources;
    private cleanupCallbacks;
    setTimeout(componentId: string, callback: () => void, delay: number, metadata?: Record<string, any>): number;
    setInterval(componentId: string, callback: () => void, delay: number, metadata?: Record<string, any>): number;
    requestAnimationFrame(componentId: string, callback: FrameRequestCallback, metadata?: Record<string, any>): TimerId;
    clearTimeout(componentId: string, id: number): void;
    clearInterval(componentId: string, id: number): void;
    cancelAnimationFrame(componentId: string, id: TimerId): void;
    addEventListener(componentId: string, target: EventTarget, type: string, listener: EventListener, options?: AddEventListenerOptions): void;
    registerDOMElement(componentId: string, element: any, cleanup?: () => void): void;
    registerReactRoot(componentId: string, root: any, unmountFn: () => void): void;
    registerCleanup(componentId: string, cleanup: () => void): void;
    registerGlobalResource(resource: ManagedResource): void;
    private addResource;
    private removeResource;
    cleanupComponent(componentId: string): void;
    cleanupGlobal(): void;
    cleanupAll(): void;
    getStats(): {
        componentCount: number;
        resourceCounts: Record<string, number>;
        globalResourceCount: number;
    };
}
export declare const resourceManager: ResourceManager;
//# sourceMappingURL=resource-manager.d.ts.map