Reflect.getPrototypeOf() JavaScript JS

The JavaScript Reflect.getPrototypeOf() method gives the prototype of an object. It is similar to the Object.getPrototypeOf(). Syntax: Reflect.getPrototypeOf(target) Parameters: target: It represents the object whose prototype has to be obtained. Return: Prototype of the specified object. Note: It will throw a TypeError if the target is not an Object. Example 1: <!DOCTYPE html> <html> <body> … Read more