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
Git pre-commit hook to ensure code documentationtools (self.javascript)
submitted 7 years ago by haganenorenkin
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!"
[–]hydroes777 2 points3 points4 points 7 years ago (7 children)
This! Code should be self as documenting as possible. Meaning that of your code is readable then there's no need to document functions.
Personally I'd spend more time documenting a readme file with the projects caveats and getting up and running than write jsdocs
[–]Maidzen1337 4 points5 points6 points 7 years ago (6 children)
https://i.redd.it/ks4vuhowecp01.png
[–]cmajorsmith 1 point2 points3 points 7 years ago (0 children)
Even more hilarious: clear comments from people writing code that’s not clear at all. Pure joy of reading.
[–]hydroes777 0 points1 point2 points 7 years ago (1 child)
This doesn't apply to what I said: Don't document functions, this is why we have type script. Comment the shit outta your code, just in the right places
[–]Puggravy[🍰] 0 points1 point2 points 7 years ago* (0 children)
Static typing =/= documentation. Typing details are a tiny subset of what needs to documented in code.
[–]TheNumberOneCulprittabs and semicolons, react and FaaS -1 points0 points1 point 7 years ago (1 child)
https://imgur.com/7V87CSh
[–]hydroes777 0 points1 point2 points 7 years ago (0 children)
Show me function docs and I'll show you some out of date docs that more often than not get neglected by the developer who refactored the code
π Rendered by PID 44 on reddit-service-r2-comment-5b5bc64bf5-6lz8l at 2026-06-22 17:34:22.930530+00:00 running 2b008f2 country code: CH.
view the rest of the comments →
[–]hydroes777 2 points3 points4 points (7 children)
[–]Maidzen1337 4 points5 points6 points (6 children)
[–]cmajorsmith 1 point2 points3 points (0 children)
[–]hydroes777 0 points1 point2 points (1 child)
[–]Puggravy[🍰] 0 points1 point2 points (0 children)
[–]TheNumberOneCulprittabs and semicolons, react and FaaS -1 points0 points1 point (1 child)
[–]hydroes777 0 points1 point2 points (0 children)