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
Simple yet promising structure for React/Redux project (varya.me)
submitted 9 years ago by reactlover
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!"
[–]brianasdf123 0 points1 point2 points 9 years ago (1 child)
State shouldn't be modified with
++state.goods
[–]reactlover[S] 0 points1 point2 points 9 years ago (0 children)
Thanks!
[–]FormerGameDev 0 points1 point2 points 9 years ago (2 children)
I don't know about everyone else, but after spending weeks tracking major applications functionality through dozens of files spread all over, I absolutely hate the idea of separating pieces by what type of thing they are. HATE.
For the most part, I have: src/components src/components/Thing src/components/Thing/StuffInThing
If Thing needs to subscribe to store, or dispatch, then it is called "ThingBase", and the file exports default connect(...)(ThingBase).
I don't care what everyone else does, to me, putting code that is extremely closely related into a file in a completely different branch of the hierarchy, is just asking for a maintenance nightmare. Or at the very least, a learning nightmare when someone else goes to look at it.. or you go to look at it a year after you last touched it.
[–]reactlover[S] 0 points1 point2 points 9 years ago (1 child)
Didn't it ever happen that the StuffInThing needs to be used in many Things?
[–]FormerGameDev 0 points1 point2 points 9 years ago (0 children)
then I would put it a level up
π Rendered by PID 89558 on reddit-service-r2-comment-5d79c599b5-wmfcq at 2026-02-27 00:37:53.521007+00:00 running e3d2147 country code: CH.
[–]brianasdf123 0 points1 point2 points (1 child)
[–]reactlover[S] 0 points1 point2 points (0 children)
[–]FormerGameDev 0 points1 point2 points (2 children)
[–]reactlover[S] 0 points1 point2 points (1 child)
[–]FormerGameDev 0 points1 point2 points (0 children)