feat: add a flag in bootstrap to enable coalesce event change detection to improve performance (#30533)

PR Close #30533
This commit is contained in:
JiaLiPassion
2019-05-17 20:50:02 +09:00
committed by Matias Niemelä
parent 4c63e6ba04
commit 21c1e14385
11 changed files with 171 additions and 21 deletions

View File

@ -624,13 +624,17 @@ export declare class NgProbeToken {
export declare class NgZone {
readonly hasPendingMacrotasks: boolean;
readonly hasPendingMicrotasks: boolean;
readonly hasPendingZoneMicrotasks: boolean;
readonly isStable: boolean;
readonly lastRequestAnimationFrameId: number;
readonly onError: EventEmitter<any>;
readonly onMicrotaskEmpty: EventEmitter<any>;
readonly onStable: EventEmitter<any>;
readonly onUnstable: EventEmitter<any>;
constructor({ enableLongStackTrace }: {
readonly shouldCoalesceEventChangeDetection: boolean;
constructor({ enableLongStackTrace, shouldCoalesceEventChangeDetection }: {
enableLongStackTrace?: boolean | undefined;
shouldCoalesceEventChangeDetection?: boolean | undefined;
});
run<T>(fn: (...args: any[]) => T, applyThis?: any, applyArgs?: any[]): T;
runGuarded<T>(fn: (...args: any[]) => T, applyThis?: any, applyArgs?: any[]): T;