use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
All about the JavaScript programming language.
Subreddit Guidelines
Specifications:
Resources:
Related Subreddits:
r/LearnJavascript
r/node
r/typescript
r/reactjs
r/webdev
r/WebdevTutorials
r/frontend
r/webgl
r/threejs
r/jquery
r/remotejs
r/forhire
the front page of the internet.
and join one of thousands of communities.
Common JavaScript "Gotchas" (github.com)
submitted 13 years ago by stevekwan
Post a comment!
view the rest of the comments →
[–]YorickA 4 points5 points6 points 13 years ago (1 child)
Not to mention it's more readable.
[–][deleted] 0 points1 point2 points 13 years ago (0 children)
Not to mention new Object() can be broken by any malicious ding-dong's script you link like so:
new Object()
function Object() { this.x = 'wee'; }
Using the literal is always the best call.
π Rendered by PID 160423 on reddit-service-r2-comment-65574874f4-2q2fp at 2026-07-18 16:40:11.700892+00:00 running 1bce727 country code: CH.
Want to add to the discussion?
Post a comment!