How to resize the grid using javascript?

I tried to resize the grid by changing the size of the div the grid is embedded. After that, the size of the grid inside the div is unchanged and the grid header and the body are separated.

Any way to resize the grid, such as set its height and width?


After changing size of container div, just call
this command will force grid view update, and component adjust inner sizes according to new size of container element.