From 773196a6b1ce90a263dbfa66df40ae91b35497a7 Mon Sep 17 00:00:00 2001 From: markostanimirovic Date: Thu, 29 Sep 2022 17:01:08 +0200 Subject: [PATCH] fix(component): replace animationFrameScheduler with requestAnimationFrame --- modules/component/src/core/tick-scheduler.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/modules/component/src/core/tick-scheduler.ts b/modules/component/src/core/tick-scheduler.ts index ce50a072a8..b59fb686f8 100644 --- a/modules/component/src/core/tick-scheduler.ts +++ b/modules/component/src/core/tick-scheduler.ts @@ -1,5 +1,4 @@ import { ApplicationRef, inject, Injectable, NgZone } from '@angular/core'; -import { animationFrameScheduler } from 'rxjs'; import { isNgZone } from './zone-helpers'; @Injectable({ @@ -28,7 +27,7 @@ export class AnimationFrameTickScheduler extends TickScheduler { schedule(): void { if (!this.isScheduled) { this.isScheduled = true; - animationFrameScheduler.schedule(() => { + requestAnimationFrame(() => { this.appRef.tick(); this.isScheduled = false; });