docs(ivy): document global debugging utilities and clean up API (#34453)

Cleans up the public API of the global debugging utilities, documents them and exposes them in the API docs.

PR Close #34453
This commit is contained in:
crisbeto
2019-12-19 21:25:42 +01:00
committed by Andrew Kushnir
parent d72cfc9d57
commit 471375adbe
14 changed files with 240 additions and 171 deletions

View File

@ -1,19 +1,27 @@
export declare function getComponent<T = {}>(element: Element): T | null;
export declare function applyChanges(component: {}): void;
export declare function getContext<T = {}>(element: Element): T | null;
export declare function getComponent<T>(element: Element): T | null;
export declare function getDebugNode(element: Node): DebugNode | null;
export declare function getContext<T>(element: Element): T | null;
export declare function getDirectives(target: {}): Array<{}>;
export declare function getDirectives(element: Element): {}[];
export declare function getHostElement<T>(directive: T): Element;
export declare function getHostElement(componentOrDirective: {}): Element;
export declare function getInjector(target: {}): Injector;
export declare function getInjector(elementOrDir: Element | {}): Injector;
export declare function getListeners(element: Element): Listener[];
export declare function getRootComponents(target: {}): any[];
export declare function getOwningComponent<T>(elementOrDir: Element | {}): T | null;
export declare function getViewComponent<T = {}>(element: Element | {}): T | null;
export declare function getRootComponents(elementOrDir: Element | {}): {}[];
export declare function markDirty<T>(component: T): void;
export interface Listener {
callback: (value: any) => any;
element: Element;
name: string;
type: 'dom' | 'output';
useCapture: boolean;
}
export declare function markDirty(component: {}): void;