> Why would you use a square bracket notation rather than a . Property > access notation? > > [] is typically only use when the property name is in a variable, which is > not the case when you write your own object. >
True - but for symbols, your only option is square brackets: var sym = new Symbol(), obj = {}; obj[sym] = 42; So if you go the private symbols route, then you're going to have *lots* of square brackets. { Kevin }
_______________________________________________ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss