😱 ES6 Symbols
Symbol
- Symbol is a new primitive.
- Symbol can be used for debugging.
- Symbols can be used as Object keys. It will not conflict with string keys.
- It can be used as class private properties
- If you don’t have the reference for the Symbol, you just can’t use it. This also means two symbols will never equal the same value, even if they have the same description.
–
references:
03 Aug 2017