Possible Duplicate:
JavaScript property access: dot notation vs. brackets?
I am now reading some of open source javascript project codes and i see that sometimes they access object property like person.name
but sometimes they access like person['name']
.
For me dot notation is so much clear against other. Dot notation is easy to write and read but in source code i see that they are sometimes used dot notation sometimes [] braces notation and i am trying to understand what is the reason of it.
What can be reason of it ?