MCPcopy
hub / github.com/angular/angularfire / runOutsideAngular

Function runOutsideAngular

src/zones.ts:99–103  ·  view source on GitHub ↗
(fn: (...args: any[]) => T)

Source from the content-addressed store, hash-verified

97}
98
99function runOutsideAngular<T>(fn: (...args: any[]) => T): T {
100 const ngZone = inject(NgZone, { optional: true });
101 if (!ngZone) {return fn();}
102 return ngZone.runOutsideAngular(() => fn());
103}
104
105function run<T>(fn: (...args: any[]) => T): T {
106 const ngZone = inject(NgZone, { optional: true });

Callers 1

ɵzoneWrapFunction · 0.85

Calls 1

fnFunction · 0.85

Tested by

no test coverage detected