@alibek.sharapov I was wondering this too... I did find this result through google from the old forum.
Really, there is no difference. It's just a matter of preference. Using bracket notation can be very flexible though. If you're doing a for/in loop, you can use bracket notation to loop through every single property in an object without knowing what properties are there beforehand (see example below).
It is indirectly said that square bracket notation should be used when property names are to be dynamically determined (when the property name is not determined until runtime).
The section in question:
@mtf: The above with throw a reference error. key is a dynamic variable, not very likely to be "key", but any of the defined property names.
Am I understanding correctly that that means dot notation can only be used when the property name is known? e.g. for property
var x = propertyKey
is okay, but where
var x is a place holder for all potential property keys within an object (and not a variable assigned to a specific key, nor a specific key's name)
console.log(obj.propertyKey) is not okay?