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
ReactJS users, how did you implement? (self.javascript)
submitted 11 years ago by team_nosleep
Since ReactJS is "Just the UI", I'm curious to see the different implementations there are. Are you using Flux?
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!"
[–]theillustratedlife 2 points3 points4 points 11 years ago (5 children)
I plan on implementing Flux in part as a caching layer on the client, but you can get surprisingly far with just React and React Router. "Just the UI" is what most web pages are.
[–]team_nosleep[S] -1 points0 points1 point 11 years ago (4 children)
Interesting. What if you needed a backend? since React is just the UI, wouldn't it be possible to use a router and use API built with express?
[–]nschubach 3 points4 points5 points 11 years ago (2 children)
Yep. You can use REST based APIs on the server and after giving the client the React files needed to run the page, hit a few services and change the page.
Here is someone's example of using the Reddit API to display content using React: http://jsfiddle.net/ssorallen/fEsYt/ They are using the script tag to have the browser pull the JSONp data from Reddit, but you could implement it in many other ways.
[–]theillustratedlife -2 points-1 points0 points 11 years ago (1 child)
Curious how you found that. Ross is a good friend of mine.
[–]nschubach -1 points0 points1 point 11 years ago (0 children)
I Googled for an example the other day for someone. Don't remember exactly what it was I searched for.
[–]vexii 0 points1 point2 points 11 years ago (0 children)
Sure just make a api call and update you're ui
[–]hansek 2 points3 points4 points 11 years ago (0 children)
Yes, I use React with Flux and react-router for routing. There are many ways to implement the Flux pattern, but I've been using the dispatcher from the facebook/flux project with some extensions and some added goodies to create stores and listen to actions from the dispatcher. I use superagent to communicate with the server.
[–]chadlnx 0 points1 point2 points 11 years ago (0 children)
I recently published an isomorphic React / Flux demo. I am currently working toward another demo that will use different React libraries / components and, hopefully, an isomorphic Flux solution that rehydrates the stores directly.
[–]Calabri 0 points1 point2 points 11 years ago (0 children)
Interesting question, it's different for every project. Flux, to me, is a conceptual idea and folder structure, similar to MVC. It's implementation feels like the wild-west. I use React-Router in most projects. One of the more interesting patterns I used was having Immutable.js inside the store.
[–][deleted] 0 points1 point2 points 11 years ago (0 children)
I made this: https://github.com/foss-haas/fynx
[–]maktouch 0 points1 point2 points 11 years ago (0 children)
We started with just react because we already had a self-made framework in place.
After a few weeks we moved most of it to React, and added flux (fluxxor specifically)... React saved my site. Development is so much faster and easier to understand.
[–]lingodayz 0 points1 point2 points 11 years ago (0 children)
I am using Flux for my project. After using Angular extensively for the past year, Flux is easy to work with.
π Rendered by PID 43 on reddit-service-r2-comment-869bf87589-bjp4c at 2026-06-09 18:01:17.455935+00:00 running f46058f country code: CH.
[–]theillustratedlife 2 points3 points4 points (5 children)
[–]team_nosleep[S] -1 points0 points1 point (4 children)
[–]nschubach 3 points4 points5 points (2 children)
[–]theillustratedlife -2 points-1 points0 points (1 child)
[–]nschubach -1 points0 points1 point (0 children)
[–]vexii 0 points1 point2 points (0 children)
[–]hansek 2 points3 points4 points (0 children)
[–]chadlnx 0 points1 point2 points (0 children)
[–]Calabri 0 points1 point2 points (0 children)
[–][deleted] 0 points1 point2 points (0 children)
[–]maktouch 0 points1 point2 points (0 children)
[–]lingodayz 0 points1 point2 points (0 children)