Y
Hacker News
new
|
ask
|
show
|
jobs
by
RobertWHurst
1534 days ago
At least in V8 they are last I checked. The symbols feature is a property privacy feature. A symbol can be treated as a private secret owned by a library thus restricting access to a property on a shared object.
1 comments
qubyte
1534 days ago
This is untrue. Symbols provide no privacy. They provide a mechanism to avoid collisions. You can even ask an object for its symbol properties:
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...
link