JavaScript Reflect.deleteProperty() MethodThe Reflect.deleteProperty() method allows to delete a property on an object. If the method returns true, that means deleting the property is successful. Otherwise, it returns false. Syntax:Parameters:target: It is the target object on which to delete the property. propertyKey: It is the name of the property to be deleted. Return value:A Boolean represents that the property was successfully deleted or not. Exceptions:A TypeError, if the target is not an Object. Browser Support:
Example 1Output: 1,2,3,,5 Example 2Output: false Example 3Output: true true true Next TopicJavaScript Reflect |
We provides tutorials and interview questions of all technology like java tutorial, android, java frameworks
G-13, 2nd Floor, Sec-3, Noida, UP, 201301, India