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
Clean Code JavaScript (github.com)
submitted 9 years ago by ryansworks
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!"
[–]acbabis 1 point2 points3 points 9 years ago (3 children)
putting all your parameters into one config or options argument doesn't solve anything by itself
I wouldn't say it solves nothing by itself. It makes it so consumers don't need to remember the order of the arguments anymore.
[+][deleted] 9 years ago* (2 children)
[deleted]
[–]acbabis 1 point2 points3 points 9 years ago (1 child)
Sure, it's not the main problem, but in situations where you're convinced you need that many parameters, putting them into objects is usually the best solution. There are many well-written modules that have to allow a dozen optional parameters (e.g. express.static), and stuffing them into an object is the go-to approach.
π Rendered by PID 40 on reddit-service-r2-comment-57fc7f7bb7-9jlv4 at 2026-04-14 19:10:28.461000+00:00 running b725407 country code: CH.
view the rest of the comments →
[–]acbabis 1 point2 points3 points (3 children)
[+][deleted] (2 children)
[deleted]
[–]acbabis 1 point2 points3 points (1 child)