Skip to content
New issue

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

ES5 property attributes are not preserved #76

Open
mbrowne opened this issue Mar 4, 2017 · 0 comments
Open

ES5 property attributes are not preserved #76

mbrowne opened this issue Mar 4, 2017 · 0 comments

Comments

@mbrowne
Copy link

mbrowne commented Mar 4, 2017

Consider the following example:

var o = {};
Object.defineProperty(o, 'foo', {enumerable:true, writable:false, value:'f'});
var o2 = clone(o);

console.log(Object.getOwnPropertyDescriptor(o2, 'foo'));

The property descriptor on the copied object specifies the property as writable even though the original property wasn't writable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant