get-prototype-descriptors
Returns all descriptors of a prototype chain while respecting prototype inheritance.
Installation
npm install --save get-prototype-descriptors
Usage
{} { return 'A'; } {} { return 'B'; } {} { return 'C' } ; let descriptors = ;
The descriptors will be flattened and descriptors from child classes will overload those of the parent.
Compatibility
get-prototype-descriptors
requires Object.getOwnPropertyDescriptors
which is not available in IE and pre-Node 6.
You may consider adding a polyfill if you need to support these environments.
License
MIT License