Data Flow

suggest change

This is an outline of a comprehensive overview.

The Flux pattern assumes unidirectional data flow.

  1. Action — a simple object describing an action type and other input data.
  2. Dispatcher — the single action receiver and callback controller. Think of it as the central hub of your application.
  3. Store — contains the application state and logic. It registers a callback with the dispatcher and emits an event to the view when a change to the data layer has occurred.
  4. View — a React component that receives the change event and data from the store. It re-renders when something has changed.

As of Flux data flow, views may also create actions and pass them to dispatcher for user interactions.

Reversed

To make it clearer, we can start from the end.

A few components may be called controller-views, because they provide the glue code to get the data from the stores and to pass data down the chain of their descendants. Controller-views represent any significant section of the page.

Formally, you’ll want to use constants for action types and helper methods (called action creators).

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents