Angular virtual scroll not working correctly for nested for loop

The Angular Material cdk-virtual-scroll-viewport property is not working correctly for nested *cdkVirtualFor or *ngFor. The viewport is split into two and the scroll does not work as expected. Please assist in listing in viewport with parent and child. <cdk-virtual-scroll-viewport itemSize="50"> <div *cdkVirtualFor="let parent of parents"> <h4>{{ parent.name }}</h4> <cdk-virtual-scroll-viewport itemSize="50"> <div *cdkVirtualFor="let child of children"> […]

JavaScript How to run timer from custom datetime?

JavaScript How to run timer from server datetime? Need to run a timer from custom datetime(past or future). Ex: Jun 15 2021 15:45:31 GMT+0530", "Tue Jun 15 2021 15:45:32 GMT+0530" (seconds) startTimer() { const dateTime = new Date(‘2021-06-15T15:45:30’); setInterval(() => { this.now = dateTime; this.startTimer(); }, 1000); } // timer is not working and it […]

By reegan29
Published
Categorized as angular, javascript, momentjs Tagged , ,

How to run timer from custom datetime?

Need to run a timer from custom datetime(past or future). Ex: Jun 15 2021 15:45:31 GMT+0530", "Tue Jun 15 2021 15:45:32 GMT+0530" (seconds) startTimer() { const dateTime = new Date(‘2021-06-15T15:45:30’); setInterval(() => { this.now = dateTime; this.startTimer(); }, 1000); } // timer is not working and it is in static. (Tue Jun 15 2021 15:45:31 […]

By reegan29
Published
Categorized as angular, javascript, momentjs Tagged , ,

Still Have Questions?


Our dedicated development team is here for you!

We can help you find answers to your question for as low as 5$.

Contact Us
faq