JavaScript Reflect Reference Last Updated : 18 Apr, 2025 Summarize Comments Improve Suggest changes Share Like Article Like Report JavaScript Reflect is a built-in object. It gives access to other methods for interceptable operations. Like most objects in JavaScript, it is not a constructor.Syntax:Reflect.function()Example: Below examples illustrate the Reflect.setPrototypeOf() method in JavaScript: JavaScript const object1 = {}; console.log(Reflect.setPrototypeOf(object1, Object.prototype)); console.log(Reflect.setPrototypeOf(object1, null)); const object2 = {}; console.log(Reflect.setPrototypeOf(Object.freeze(object2), null)); let object3 = { gfg() { return 'value'; } } let obj = { geeks() { return 'answer'; } } Object.setPrototypeOf(obj, object3); console.dir(obj); console.log(obj.geeks()); console.log(obj.gfg()); Outputtrue true false { geeks: [Function: geeks] } answer valueNote: There are no Properties or Contructor in Reflect Object.The complete list of JavaScript Reflect are listed below:String Methods: JavaScript methods are actions that can be performed on objects. There are two types of String methods in JavaScript.Static Method: If the method is called using the Reflect class itself then it is called a static method. Instance Methods Descriptionapply()Call a function using the specified argument.construct()It gives the added option to specify a different prototype.defineProperty()Allow the precise addition to or modification of a property on an object.deleteProperty()Returns a Boolean value which indicates whether the property was successfully deleted.get()This method always returns the value of the property.getOwnPropertyDescriptor()Get the descriptor of an object.getPrototypeOf()Return the prototype of the specified object.has()Check whether the property exists in an object or not. It works like an operator as a function.isExtensible()Check whether an object is extensible or not.ownKeys()Return an array of the target object’s own property keys and it ignores the inherited properties.preventExtensions()Prevent the future extensions to the object which means prevent from adding new properties to the object.set()Set the value of an object property.setPrototypeOf()Set the prototype of a specified object to another object or to Null. Comment More infoAdvertise with us Next Article JavaScript Reflect Reference K kartik Follow Improve Article Tags : JavaScript Web Technologies JavaScript-Reflect Similar Reads JavaScript Reflect JavaScript Reflect is a built-in object that gives access to other elements for interceptable operations. This object can be used to check whether an object has a particular property or to change or add new properties to an existing object. This object cannot be explicitly created using the new keyw 2 min read JavaScript Reflect ownKeys() Method JaScript Reflect.ownKeys() method in Javascript is used to return an array of the target object's own property keys and it ignores the inherited properties. Syntax: Reflect.ownKeys( obj ) Parameters: This method accepts a single parameter as mentioned above and described below: Obj: This parameter h 2 min read JavaScript Reflect get() Method JavaScript Reflect.get() method in JavaScript is used to allow users to get the property from an object as a function. This method always returns the value of the property. Syntax: Reflect.get(target, propertyKey, receiver) Parameters: This method accepts three parameters as mentioned above and desc 2 min read JavaScript Reflect set() Method JavaScript Reflect.set() method in JavaScript is used to set the value of an object property. It returns a Boolean value true if the property is successfully set else it returns false. Syntax: Reflect.set(obj, Key, value, receiver) Parameters: This method accepts four parameters as mentioned above a 2 min read JavaScript Reflect has() Method JavaScript Reflect.has() method in JavaScript is used to check whether the property exists in an object or not. It works like the in operator as a function. Syntax: Reflect.has(target, propertyKey) Parameters: This method accepts two parameters as mentioned above and described below: target: This pa 2 min read Like