Given a resizable grid, what is "proper" way to programmatically trigger the auto-resize of a column (or columns)?
1 Answer, 1 is accepted
1
Accepted
Konstantin Dikov
Telerik team
answered on 27 Jul 2022, 06:07 PM
Hello John,
The Grid API does not provide a direct way for using the auto-resize functionality, but you can use a workaround where a double click event is triggered for the resize element for each column after the initial rendering. I have prepared a simple example demonstrating such implementation:
If you are using Hooks you can use React.useEffect instead of componentDidMount.
Please let me know if further questions arise.
Regards,
Konstantin Dikov
Progress Telerik
Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.