Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
SeriousM
· 7y ago · 0 comments
I disagree with the "object literal" because it hides the traces when which is taken. Sometimes it's better to write more self explaining code instead saving a vew lines.
Comments
[–]
ryanpetrich
7y ago
It’s also dangerous in JavaScript where properties of the Object prototype can mistakenly be dereferenced instead of the default/fallthrough case.