You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
But after doing operations on both, the changes are reflected in both objects. I am doing this because the same npm is used by parent and other npm modules and I want their own copies to avoid other issues.
Based on the documentation it looks like clone supports deep copy by default. Any help in achieving it is appreciated.
The text was updated successfully, but these errors were encountered:
I am trying to clone an npm object like below.
const obj1 = clone( require('an-npm-module'));
const obj2 = clone( require('an-npm-module'));
But after doing operations on both, the changes are reflected in both objects. I am doing this because the same npm is used by parent and other npm modules and I want their own copies to avoid other issues.
Based on the documentation it looks like clone supports deep copy by default. Any help in achieving it is appreciated.
The text was updated successfully, but these errors were encountered: