The type of the values of the object.
The type of the object.
The object whose properties are to be converted into getter functions.
Rest
...propertyNames: ObjectKey[]The names of the properties to be converted into getter functions.
The object with the specified properties converted into getter functions.
Throws an error if the property descriptor for a specified property name is not found.
const obj = { a: 1, b: 2, c: 3 };
objPropertyValueToGetter(obj, 'a', 'b');
obj.a;;
//=> 1
obj.b;;
//=> 2
obj.c;;
//=> 3
Generated using TypeDoc
Converts the specified properties of an object into getter functions.