Where communities thrive

  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
Repo info
Arthur Schwaiger
Hi ! I'm new to React/Flux/Fluxxor/[insert Flu-Library] and looking for advices. I have complex models class (not especially complex data, but complex methods, nested objects inside them, ...). In my current app, I directly play with these class like this: "var hasIntersections = MyGlobalStore.project.getObjectById('myObject').checkIfIntersects(); if (hasIntersections) MyGlobalStore.project.getObjectById('anotherObject').setIntersection(true);" . That's super easy because all the logic is behind my model objects and I easily fetch child objects in my project. I find the Flux/Fluxxor unidirectional flow really interseting, but I don't see how to handle such complex class (Project, Project.Objects, Project.Object.Transformations, ...) in the store. Do you have some advices ? Everyone told me to forget about "models" and think the Flux way (ie functions in store), but I'm afraid to lost my well-organized-and-full-of-usefull-methods class, and furthermore all the relations between my class models ("Project.getObject('myObject').getTransformation('transformationId')")
@all need help...I tried but not able to proceed https://gist.github.com/js08/0ec3d70dfda76d7e9fb4
I'm following the guide for handling async actions here: http://fluxxor.com/guides/async-data.html - what's the best way to make an instance of an api client available to the action? Should I pass it in to the component and then pass it to the action as an argument upon dispatch?
The example in the guide used a global variable to store the client api which was then available to the action creator
But I want to use an instance of an api client which isn't available in the global scope
Another question - what's a good way to dispatch multiple actions that need to happen one after the other?

i have fluxxor app with react 0.13 and react router 0.13. i want to update dependencies and use latest react with react-router 2. previously react router had an instance that i could pass to stores like this:

var router = Router.create({
  routes: routes,
  location: Router.HistoryLocation

var flux = new Fluxxor.Flux(getStores({router: router}), actions);

but now there is no such instance
i haven't yet understand how to make transitions from stores

solved this problem %)
Is it a good practice / good design principle to have components "communicate" with stores only on the very bottom level? I propagate the flux instance from the root app down through all levels of component hierarchy and have very atomic components speak with e.g. Input. I am asking because I read that the best practice is to have state in the top level and to propagate it down the hierarchy to child components
Arthur Schwaiger
It's not a good practice
Actually, you should keep in mind that the less you "fluxify" a component (listen to store, trigger actions), the more it's reusable in another part of your app
You shouldn't use flux instance in your Input, never
Arthur Schwaiger
The solution is to create smart and dumb components. Dump components are "real" React components, which receive props and display content based on these props. On the opposite, smart components are kind of parent containers that are connected to flux and are responsible to fetch data from store, call actions, and so on.
vivek poddar
@/all guys I need to learn maintainable and flexible front end architecture, I have experience with Angularjs but I am not specific to any framwork, I need to learn best practices, is this the right place?
Arthur Schwaiger
Maybe you should start with Flux concept. Then start with à Flux implementation like fluxxor (you also have Redux or Alt.js)
Note that Flux concept is better with React.js or à similar view layer
btw ReactMixin.onClass(NewCarePlan, Fluxxor.FluxMixin(React)); seems to be working Thank you, saved me a lot of trouble! :D Please put this in the docs!
Jay Nanavati
Hey - Im trying to understand the "global state" issues with flux architectures
Nitish Dhar
Hello people
Anyone around?
I need some help with dependent stores e.g. Data is fetched for one store and now in the UI I need to fetch data for its association.. How can I do this after the first store is done & has completed its actions
Basically how can I call an action after a previous action is done
Punita Ojha
This message was deleted


  • I am trying to learn rxjs.
  • I have a simple application retrieving values from api through rxjs.
  • I am trying to achieve Set token expiration to 2 minutes and if backend service responds with a 'Unauthorized' error, get the token again and use it.
  • can you guys tell me how to add it to my code.
  • providing my code below.


                .subscribe(users => {
                    console.log('users ready', users);

                    var grid = $("#grid").kendoGrid({
                        dataSource: {


  • initialy when I go sports.com and from there if I go to players it works fine.
  • after that in the same players url if I enter I am getting the below error message.
  • any idea how to fix in js



HTTP Status 404Not Found

Type Status Report

Message /players/playersJumping

Description The origin server did not find a current representation for the target resource or is not willing to disclose that one exists.

Apache Tomcat/8.5.23
Mudit Khurana
Hi I have some questions about making ajax calls in fluxxor/react architecture. Is this room still active?