Lattice Grid Buy a licence

The grid (rendering) · console.warn

Column '{colId}' template sets '{attr}'. Inline event handlers are not allowed in templates; use grid events or a component renderer. The attribute was dropped.

Printed by The grid (rendering), prefixed [lattice], since 1.0.1.

Warnings referencetpl-attr:*:*

Identifier
tpl-attr:*:*
Raised by
The grid (rendering)
Since
1.0.1

What happened

An on… attribute in a cell template is an inline event handler, which would execute template-authored code on every paint. The attribute is dropped; the element is still rendered without it, so the cell looks right and does nothing when clicked.

The fix

Listen for the grid's own cell events, or use a component renderer that attaches its own listeners.

The smallest fix

grid.on('cell:click', ({ key, colId }) => open(key, colId));

Reference

Covered in full at the API reference.