I'm doing a dropList with angular material, and I have the following problem:
I'm using the index of the ngForm as the value for the attribute name of the form, if I change the position of the empty element at the end (moving with mouse) and then delete it I get this:
Visually it works correctly, however if we look at the value of the ngForm fields we see that the values are not correct since the name has not been updated after deleting the element
One way to solve this is to put a Math.random in the name attribute, but this does not seem like nice solution
Any way to solve this problem?