Take a look at this example: link
In it I have two arrays:
__options e __defaultOptions;
When I start dou pushing in __options inserting the __defaultOptions object. Later I change the value of the object in position 0, set in the field "maxsize" the value 1500.
It turns out that the value is also assigned to all other positions in the array.
I imagine you are only referencing the __defaultOptions object in the array positions, being the same object in all positions, so when I change the value in one of the positions, all of them have their value changed.
How can I get around this?
Is there any way to import the data of an object itself, and not reference the object?