Skip to content

Commit 7ffb6ce

Browse files
authored
fix typo "colector" => "collector"
Fix typo in line 287
1 parent e1a3f63 commit 7ffb6ce

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

1-js/05-data-types/08-weakmap-weakset/article.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,7 @@ The most notable limitation of `WeakMap` and `WeakSet` is the absence of iterati
284284

285285
`WeakSet` is `Set`-like collection that stores only objects and removes them once they become inaccessible by other means.
286286

287-
It's main advantages are that they have weak reference to objects, so they can easily be removed by garbage colector.
287+
It's main advantages are that they have weak reference to objects, so they can easily be removed by garbage collector.
288288
That comes at the cost of not having support for `clear`, `size`, `keys`, `values` ...
289289

290290
`WeakMap` and `WeakSet` are used as "secondary" data structures in addition to the "primary" object storage. Once the object is removed from the primary storage, if it is only found as the key of `WeakMap` or in a `WeakSet`, it will be cleaned up automatically.

0 commit comments

Comments
 (0)