@huolala-tech/page-spy-browser
Version:
A developer tool for debugging remote web page.
41 lines (40 loc) • 1.3 kB
TypeScript
import { Client } from '@huolala-tech/page-spy-base';
import type { PageSpyPlugin, PluginOrder } from '@huolala-tech/page-spy-types';
import type { InitConfig } from './config';
import Request from './api';
import { Config } from './config';
type UpdateConfig = {
title?: string;
project?: string;
};
declare class PageSpy {
static instance: PageSpy | null;
static plugins: Record<PluginOrder | 'normal', PageSpyPlugin[]>;
static get pluginsWithOrder(): PageSpyPlugin[];
static registerPlugin(plugin: PageSpyPlugin): void;
static client: Client;
root: HTMLElement | null;
version: string;
request: Request | null;
address: string;
socketStore: import("./helpers/socket").WebSocketStore;
config: Config;
cacheTimer: ReturnType<typeof setInterval> | null;
eventBus: EventTarget;
private visibilityChangeHandler;
constructor(ic?: InitConfig);
private init;
private updateConfiguration;
private cacheIsInvalid;
private createNewConnection;
private useOldConnection;
private refreshRoomInfo;
private saveSession;
private triggerPlugins;
private render;
private startRender;
private handleDeviceDPR;
updateRoomInfo(obj: UpdateConfig): void;
abort(): void;
}
export default PageSpy;