V13, Grid without header

I am using a Grid in my Vaadin 13 application. But actually I want to show only data and have no need for column headers. Who do i remove the column header generated by default?


I believe it’s not possible to remove a header row per se, but it is possible to never add one in the first place. This means, you cannot intitialize your Grid with a class as parameter since this will set a header for each automatically generated column. You’ll have to add every column you want yourself, and be sure to never set a header for any column.

I tested this just now, using following code. The displayed Grid indeed has no header row, only data.

Grid<Object> gridWithoutHeaders = new Grid<>();
gridWithoutHeaders.addColumn(item -> "column A");
gridWithoutHeaders.addColumn(item -> "column B");
gridWithoutHeaders.addColumn(item -> "column C");
gridWithoutHeaders.setItems("x", "y", "z");