Hacker News new | past | comments | ask | show | jobs | submit login

The reason for outlawing the first syntax is that it isn't a legal javascript literal in the case where the key is a javascript reserved word (if we change 'foo' to 'for' in this example).



Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: