Search code examples
javavaadinvaadin8vaadin-grid

How do you set the height of a Vaadin 8 Grid to be undefined?


I've tried both Grid.setUndefined() and Grid.setHeight("-1px") and neither works. They should both be doing the same but if my grid only has say 3 items then the bottom of the grid is empty and the height is significantly taller than 3 rows.


Solution

  • Try setHeightByRows method (Java doc).