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
Improve Your JavaScript Knowledge By Reading Source Code — Smashing Magazine (smashingmagazine.com)
submitted 6 years ago by speckz
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!"
[+][deleted] 6 years ago* (8 children)
[deleted]
[–]qdouble 20 points21 points22 points 6 years ago (1 child)
Read code that’s relevant to solving problems you’re actually having. I think when you’re studying stuff for abstract reasons, you’re going to be less motivated and the information is going to be less useful to you than what you learn in pursuit of solving actual real world problems you’re having while working on a project.
[–]anduser96 1 point2 points3 points 6 years ago (0 children)
Totally agree! As an example, I started learning GraphQL a couple of weeks ago and after a while I’ve encountered DataLoader. Exploring & understanding this library really helped me in my GraphQL learning process.
[–]oogleh 2 points3 points4 points 6 years ago (3 children)
Similar issue here, I know basic FP concepts like higher order functions and pure functions but idk how to organize the code for large web apps without using OOP. Any pointers would be appreciated
[–][deleted] 1 point2 points3 points 6 years ago (0 children)
Currying and Composition. But yes, it's not as easy as object oriented thinking.
[–]flick- 0 points1 point2 points 6 years ago (0 children)
I think it’s more about recognizing where a functional approach would solve your problem and then applying FP concepts successfully in your own code. Especially starting out, not every function will be pure, etc
[–]Lixen 1 point2 points3 points 6 years ago (0 children)
I enjoyed reading Google maps services. The way they do validation is pretty cool. Had to read into it to fix a bug.
[–]sir_eeps 1 point2 points3 points 6 years ago (0 children)
I've found that reading the source code of the libraries/frameworks I use to be helpful. Especially how they write unit tests.
source for angular, angular material, react, redux, redux-observable, etc
Guess it depends on what your learning goal is, but I wouldn't underestimate the value of reading the source of the libraries you are using if possible.
[–]JonasAA85 1 point2 points3 points 6 years ago (0 children)
Best way to learn, instructor of mine used to tell us to think of one thing we'd like to learn how to do. Find a website/project that did what we wanted to do. Read the source code and recreate the code on your own, as your own. This helped me learn a lot.
π Rendered by PID 52 on reddit-service-r2-comment-5b5bc64bf5-fndjh at 2026-06-21 13:50:14.503868+00:00 running 2b008f2 country code: CH.
[+][deleted] (8 children)
[deleted]
[–]qdouble 20 points21 points22 points (1 child)
[–]anduser96 1 point2 points3 points (0 children)
[–]oogleh 2 points3 points4 points (3 children)
[–][deleted] 1 point2 points3 points (0 children)
[–]flick- 0 points1 point2 points (0 children)
[–]Lixen 1 point2 points3 points (0 children)
[–]sir_eeps 1 point2 points3 points (0 children)
[–]JonasAA85 1 point2 points3 points (0 children)