We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
文章里的例子浅拷贝就是用=赋值,但是浅拷贝指的不是指浅层次的拷贝?在第一层发生改变不会影响原有变量,是我理解错了吗?
=
var a = { name: 'hello' }; // 这种不是浅拷贝吗? var b = { ...a }; // 例子说这种是浅拷贝? var c = a;
The text was updated successfully, but these errors were encountered:
两种都叫做浅拷贝但是两种的拷贝结果还是有所不同的,具体可以了解https://blog.csdn.net/m0_61825758/article/details/131483976?spm=1001.2014.3001.5501,个人见解可以参考一下。
Sorry, something went wrong.
No branches or pull requests
文章里的例子浅拷贝就是用
=
赋值,但是浅拷贝指的不是指浅层次的拷贝?在第一层发生改变不会影响原有变量,是我理解错了吗?The text was updated successfully, but these errors were encountered: