delete object.property or delete object[property]
- Delete keyword deletes the both value of the property and the property also. After deletion, the property can not be used.
- The delete operator is designed to use on object properties. It can not be used on variables or functions.
Example 1: This example deletes the address property of an object.
Example 2: This example deletes the age property of an object.
My Personal Notes arrow_drop_up