Questions tagged [reactjs-flux]

Flux is the application architecture that Facebook uses for building client-side web applications with React. It complements React's composable view components by utilizing a unidirectional data flow.

Flux is the application architecture that Facebook uses for building client-side web applications with React. It complements React's composable view components by utilizing a unidirectional data flow.

Flux applications have three major parts: the dispatcher(s), the store(s), and the view(s) (React components).

Flux eschews MVC in favor of a unidirectional data flow. When a user interacts with a React view, the view propagates an action through a central dispatcher, to the various stores that hold the application's data and business logic, which updates all of the views that are affected. This works especially well with React's declarative programming style, which allows the store to send updates without specifying how to transition views between states.

###Some popular implementations of Flux


Related tags

822 questions
0
votes
1 answer

how to get which store has sent emit.change in getStateFromFlux

I am using Fluxxor and React Js and stuck with the following problem: My React class is subscribed to several stores using mixins. My stores send this.emit("change") and I react to them in the function getStateFromFlux of the React class. But I want…
Bill Lumbert
  • 4,633
  • 3
  • 20
  • 30
0
votes
1 answer

Warning: is being rendered by both [Unknown] and [Unknown]

I am getting this error while working with react: Warning: is being rendered by both [Unknown] and [Unknown] using the same key (null) in the same place. Currently, this means that they don't preserve state. This behavior…
0
votes
2 answers

How to make initial authenticated request with token from local storage?

I'm using vanilla flux with some utils for communicating with my APIs. On initial page load I'd like to read some token from local storage and then make a request to my API to get my data. I've got a LocalStorageUtils.js library for interacting with…
zemirco
  • 16,171
  • 8
  • 62
  • 96
0
votes
1 answer

CSS setting on in SVG with ReactJS

I have ReactJS component with < path > tag.I cannot set CSS property in this < path > tag. Main issue is, For my application i cannot wrap < div > tags in render() function. How to add CSS like back ground images in tag.
0
votes
1 answer

How to pass Parameters with require tag in React

I am implementing a dynamic rendering in React in that I am using syntax like var Set=require('../../'+RecivedData.Id); React.render(,document.getElementById("secondCol")); and my CustomComponent looks like…
Dhaval Patel
  • 7,471
  • 6
  • 37
  • 70
0
votes
1 answer

Async requests with data from store

I just started using refluxjs/react with webpack. I really liked the listenAndPromise async pattern, but I've encountered a problem. I got the following code: Action: var ResumeService = require('services/ResumeService'); var ResumeActions =…
Deepsy
  • 3,769
  • 7
  • 39
  • 71
0
votes
2 answers

Isomorphic Flux - get data on server for components

In my recent applications I've been using Flux (with flummox - http://acdlite.github.io/flummox) on server per request to make isomorphic rendering. Generally it looked as follows: app.use(createFluxPerRequest); app.get('/some-route', (req, res) =>…
Kosmetika
  • 20,774
  • 37
  • 108
  • 172
0
votes
1 answer

Should I pass all the state in every change from store to component?

I am new on React and Flux and I am making an app that will have an input (like the name or the title), and below a list of n things. How should I handle the event listeners? I saw in the TODO example of flux…
Facundo Matteo
  • 2,347
  • 2
  • 16
  • 19
0
votes
3 answers

How can I modify the props of one child component from a separate child component?

I am working on a scheduling application using Reactjs & Flux. In the application, a user will need to be able to select a specific shift and then assign an employee to cover it. Employee assignment will occur by clicking on an employee's name in a…
flyingace
  • 1,707
  • 17
  • 24
0
votes
1 answer

ReactJS: How to optimise top-down render flow

Looking at Facebook's Flux TodoMVC example (https://github.com/facebook/flux/tree/master/examples/flux-todomvc/) makes me wonder how this approach scales. In the example the store is updated onBlur/Enter keypress of a new entry, but what if we…
Dominic
  • 62,658
  • 20
  • 139
  • 163
0
votes
1 answer

Where do we place assets (like pictures) and how do we load them on a React + Flux web app component?

I'm creating a React + Flux web app with a file structure that looks like this: MyApp |--- |---scripts |---app.jsx |---actions |---components |---HomePage.react.jsx |---NotFoundPage.react.jsx |--- ...etc …
SudoPlz
  • 20,996
  • 12
  • 82
  • 123
0
votes
1 answer

How to handle Flux action dependencies

I am working on a JS application using the Flux architecture. Among other things, the application displays a list of contacts and on each of them you can add or remove them from your contact book. The application is doing optimistic UI updates, so…
Gregory
  • 557
  • 6
  • 17
0
votes
1 answer

The component handles the form submission by calling its own callback? What does calling its own callback mean in this context?

I am learning about flux architecture for reactjs, while reading this article: https://medium.com/brigade-engineering/what-is-the-flux-application-architecture-b57ebca85b9e I can not seem to get what does the author means by "component handles the…
Haris Khan
  • 171
  • 1
  • 2
  • 10
0
votes
0 answers

React - REST Defined List of components by REST

I'm going to explain what I'am trying to achieve in my Flux/React application. This is my routing : var routes = (
Asso
  • 47
  • 8
0
votes
1 answer

ReactJS + Flux setState not working on single click

I'm writing my first reactjs + flux application and I have managed to get the basic code working. However, there is a list, which populates another list depending on which list item is clicked. This was working fine until I had my list data…
user4773422
  • 75
  • 1
  • 2
  • 6