in my code i have this:
ngAfterViewInit() {
// exposing scheduling engine to be easily accessible from console
window.scheduler = this.scheduler.schedulerEngine;
// Initialize the start view to the first day of the current month
const initialDate = new Date();
initialDate.setDate(1);
window.scheduler.scrollToDate(initialDate, { block: 'start' });
}
TypeError: me.viewport.round is not a function
at SubGridScroller.getDeltaTo (https://localhost:9876/_karma_webpack_/src/assets/scheduler/scheduler.module.js:15521:1)
at SubGridScroller.scrollIntoView (https://localhost:9876/_karma_webpack_/src/assets/scheduler/scheduler.module.js:70543:31)
at Scheduler.scrollToCoordinate (https://localhost:9876/_karma_webpack_/src/assets/scheduler/scheduler.module.js:103999:1)
at Scheduler.scrollToDate (https://localhost:9876/_karma_webpack_/src/assets/scheduler/scheduler.module.js:103950:1)
at GanttViewComponent../src/app/dashboard/gantt-view-container/gant-view/gantt-view.component.ts.GanttViewComponent.ngAfterViewInit (https://localhost:9876/_karma_webpack_/src/app/dashboard/gantt-view-container/gant-view/gantt-view.component.ts:156:22)
at callProviderLifecycles (https://localhost:9876/_karma_webpack_/node_modules/@angular/core/fesm5/core.js:21414:1)
at callElementProvidersLifecycles (https://localhost:9876/_karma_webpack_/node_modules/@angular/core/fesm5/core.js:21388:1)
at callLifecycleHooksChildrenFirst (https://localhost:9876/_karma_webpack_/node_modules/@angular/core/fesm5/core.js:21378:1)
at checkAndUpdateView (https://localhost:9876/_karma_webpack_/node_modules/@angular/core/fesm5/core.js:29448:1)
at callWithDebugContext (https://localhost:9876/_karma_webpack_/node_modules/@angular/core/fesm5/core.js:30309:1)
if i remove:
window.scheduler.scrollToDate(initialDate, { block: 'start' });
i have no more error...
do you have an idea ?