I have a userdata object in my database that is fetched on website load.
The user data could be up to multiple megabytes.
For the purposes of cleaner code and organization I would like to do the following:
Get all user data into object
Store some children of this user data object into separate lists
However, I wouldn't want to duplicate this data multiple times when it could be so large and have a mild impact on client ram.
I know javascript will often times just copy the memory address of a list when you set it so all I want to know is if that will actually happen?
For example does:
list = object.child;
Create a copy of that object in memory or just reference the already existing data? Is there anything special I have to do to ensure this?
2021年3月27日星期六
Copy memory address of list JavaScript
订阅:
博文评论 (Atom)
没有评论:
发表评论