-
Notifications
You must be signed in to change notification settings - Fork 27k
Closed
Milestone
Description
Which @angular/* package(s) are the source of the bug?
forms
Is this a regression?
No
Description
When using @for to render an array of fields from a signal form instance, @for does not properly track changes to the order of array values.
The reproduction demonstrates the behavior of @for when used to render an array whose values are rearranged. After the initial render the first DOM element rendered for each array item is colored red with a dashed border.
When the array elements are reordered, we'd expect their corresponding rendered <input> elements to be reordered in the DOM.
- This works as expected for an array. No bindings are updated, and the DOM elements are reordered.
- This does not work as expected for an array of fields. Bindings are updated, and the DOM elements are left untouched. Superficially, this appears to work, as the value in the inputs is swapped. However, as demonstrated by the red dashed border, one can observe that the input itself is not swapped as expected.
Please provide a link to a minimal reproduction of the bug
msmallest and sebayomhaboost
Metadata
Metadata
Assignees
Type
Projects
Status
Done