0

I have user angular material's CDK virtual scroll for virtual. The virtual scroll fetches values of table data from a function. In the end of function I check the width of table which is inside virtual scroll by using document.getElementbyId("Id").OffsetWidth So apparently, this method is called everytime when I scroll. This causes some weird behavior in rendering and the rows comes up and down for some time even if i leave scroll. Please note that If I remove OffsetWidth then there is no problem document.getElementbyId("Id").Only when I do offset width then their is rendering problem. Can someone explain to me this behavior and how can i get the width of rows/table after it is finished rendering.

0 Answers0