| [ Web Proxy ] |
| Viewing: https://developer.mozilla.org/es/docs/Web/JavaScript/Reference/Global_Objects/Reflect | [Back] [Original] |
Get to know MDN better
Esta pgina ha sido traducida del ingls por la comunidad. Aprende ms y nete a la comunidad de MDN Web Docs.
This feature is well established and works across many devices and browser versions. Its been available across browsers since septiembre de 2016.
Reflect es un objecto incorporado que proporciona metodos para interceptar operaciones de javascript. Los mtodos son los mismos que los de proxy handlers. Reflect no es un objeto de funciones y por lo tanto no puede ser construido.
A diferencia de la mayoria de los objetos globales, Reflect no es un constructor. No puede ser instanciado con un operador new o invocando el objecto Reflect como una funcin. Todas las propiedades y mtodos de Reflect son estticos (igual que los del objeto Math).
El objeto Reflect proporciona las siguientes funciones estticas con los mismos nombres de los mtodos de proxy handler. Algunos de estos mtodos son correspondientes a los mtodos de Object.
Reflect.apply()Calls a target function with arguments as specified by the args parameter. See also Function.prototype.apply().
Reflect.construct()The new operator as a function. Equivalent to calling new target(...args).
Reflect.defineProperty()Similar to Object.defineProperty(). Returns a Boolean.
Reflect.deleteProperty()The delete operator as a function. Equivalent to calling delete target[name].
Reflect.get()A function that returns the value of properties.
Reflect.getOwnPropertyDescriptor()Similar to Object.getOwnPropertyDescriptor(). Returns a property descriptor of the given property if it exists on the object, undefined otherwise.
Reflect.getPrototypeOf()Same as Object.getPrototypeOf().
Reflect.has()The in operator as function. Returns a boolean indicating whether an own or inherited property exists.
Reflect.isExtensible()Same as Object.isExtensible().
Reflect.ownKeys()Returns an array of the target object's own (not inherited) property keys.
Reflect.preventExtensions()Similar to Object.preventExtensions(). Returns a Boolean.
Reflect.set()A function that assigns values to properties. Returns a Boolean that is true if the update was successful.
Reflect.setPrototypeOf()A function that sets the prototype of an object.
| Specification |
|---|
| ECMAScript 2027 LanguageSpecification # sec-reflect-object |
This page was last modified on 29 may 2026 by MDN contributors.
Your blueprint for a better internet.
Portions of this content are 19982026 by individual mozilla.org contributors. Content available under a Creative Commons license.
| Web Proxy Viewer | New URL | Original Page |