javascript - Does Object.freeze() cause the assigned object to be immutable? -


if write following code:

var foo = [1, 2, 3, 4]; var bar = foo; object.freeze(bar); 

does mean foo immutable?

if not, how can bar remain constant if foo updated?


Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -