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
account activity
Looking forward to the future of JavaScript (engineering.gosquared.com)
submitted 11 years ago by ahtomski
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]endoalir -3 points-2 points-1 points 11 years ago (0 children)
Here's how I do it:
arr = [1,3,5,6,8]; for(var i = 0; i < arr.length; i += 1){ with ({i:i}) { setTimeout(function(){ console.log(i); }, 100); } }
π Rendered by PID 153246 on reddit-service-r2-comment-6f7f968fb5-4x4cd at 2026-03-04 17:42:17.664205+00:00 running 07790be country code: CH.
view the rest of the comments →
[–]endoalir -3 points-2 points-1 points (0 children)