Our blazing fast Grid component built with pure JavaScript
Hi
Is it possible to bind a key (delete and/or backspace) to delete the selected row from a grid instead of right clicking and using the context menu?
Thanks
Ben
Hello.
You can listen to keydown event:
EventHelper.on({
element : grid.element,
keydown : event => {
if (event.key === 'Delete') {
grid.selectedRecord.remove();
}
}
});
Also I'd check that event target is a cell inside the grid.