78
JavaScript WeakSet delete() method
The JavaScript WeakSet delete() method is used to remove the specified object from WeakSet object.
Syntax
The delete() method is represented by the following syntax:
JavaScript WeakSet delete() method example
Let’s see an example to delete the specified elements from the WeakSet object.
Output:
Element present before invoking delete() method: true Element present after invoking delete() method: false
Next TopicWeakSet has() Method