Home Forums Chart Support React Chart Resize To Containing div. Reply To: React Chart Resize To Containing div.

#38810

@pncookson,

By default, the height of the container depends on its content. When setting the height of child elements in percentage, the parent element’s height must be set explicitly since the child element’s height is calculated as a percentage of the defined parent element’s height. (In your case, you are setting the height of both parent and child elements in percentage). Setting the height of the body element explicitly to 100vh seems to be working fine.

Please take a look at this Stackblitz for an example.


Thangaraj Raman
Team CanvasJS