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

Handle non-enumerable/writable/configurable properties #8

Open
Rich-Harris opened this issue Mar 27, 2018 · 0 comments
Open

Handle non-enumerable/writable/configurable properties #8

Rich-Harris opened this issue Mar 27, 2018 · 0 comments

Comments

@Rich-Harris
Copy link
Owner

Currently, devalue will ignore non-enumerable properties. It could use Object.getOwnPropertyDescriptors instead and handle those, correctly setting writable, enumerable and configurable.

With that, { foo: 1 } would just be the (common) special case where writable, enumerable and configurable are all true.

At the same time, we would throw on getters and setters, since devalue doesn't serialize functions.

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