The Reflect.setPrototypeOf() is used to set the internal [[prototype]] property's value of an object. The Reflect.setPrototypeOf() method will return true if the internal [[prototype]] property's value was set successfully. Otherwise, it will return false.
Here is a code example that demonstrates how to use it:
var obj = {}; Reflect.setPrototypeOf(obj, { name: "Eden" }); console.log(obj.name); //Output "Eden"