Is it possible to make a slick grid control auto-size its height to between a min-max range to fit the number of rows?

Viewed 13539

I'm creating a website where a grid might have few rows or it might have many.

When there are only a few rows a lot of space is wasted in the grid on empty space.

Ideally I would like to be able to set a minimum height and a maximum height and then have the slick grid auto-size itself within that range based on the number of rows.

I've had a search around and found that there's an option for making the grid auto-size to the number of rows but it's apparently incompatible with paging.

var gridOptions = { autoHeight:true };

How to get slickgrid div to resize with size of table

It also seems you can't set a maximum height; it'll keep expanding until everything is displayed.

Does anyone have any solutions or suggestions?

2 Answers
Related