reordering columns

Hello I’m working with vaadin-grid whose UX requires the reordering of the columns to be done from outside the drag and drop functionality. Perhaps by passing in an array (this is open to suggestion). I’ve been looking through the API but nothing has lead to any success. Any advice? I should add I’m working in Polymer

There is no way of doing that at the moment as far as I know. Could you file a feature request ticket in GitHub? https://github.com/vaadin/vaadin-grid/issues

Thanks,
Marcus

You should be able to control the order of the columns by defining them with a [<dom-repeat>]
(https://www.polymer-project.org/2.0/docs/api/elements/Polymer.DomRepeat) helper and then modifying the items array’s order.

The <vaadin-grid-column> elements can be reordered in the DOM manually also, and this should update the actual visible column order in grid.

For the manual reordering of the vaadin-grid-columns can that be done outside drag and drop functionality, and if so how?

Should work with plain DOM API’s. For example grid.appendChild(grid.querySelector('vaadin-grid-column'))