ux
ux copied to clipboard
[LiveComponent] Reversing order breaks in for loop with data-poll
Hi,
I am working on a demo todo app using LiveComponent. The project is here: https://github.com/sandoche/Symfony-ux-live-component-todo-list/tree/issue-reverse (I created a specific branch for this issue)
It looks like this:
When I add a task and I leave the default sorting of tasks, the task added go to the last as expected.
When I change the sorting order in the query, or in the twig view it breaks as you can see in the screenshot below:
I just added My last added task
instead I see Faire vaisselle
also the checkbox didn't appear.
Here is the template of the component containing the reverse
:
https://github.com/sandoche/Symfony-ux-live-component-todo-list/blob/issue-reverse/templates/components/todo_list.html.twig
This issue may be somehow linked to this one: https://github.com/symfony/ux/issues/145