Sha256: d4c69fd1e6aeff16ad4f5b72ae7c72a4520e6303331181401cc85ccde59c7a68

Contents?: true

Size: 1.1 KB

Versions: 20

Compression:

Stored size: 1.1 KB

Contents

# Communication between React Components and Redux Reducers

## Communication Between Components
See https://facebook.github.io/react/tips/communicate-between-components.html

# Redux Reducers
Documentation of generated Redux code for reducers.

## Example
The `helloWorld/reducers/index.jsx` example that results from running the generator with the Redux option may be slightly confusing because of its simplicity. For clarity, what follows is a more fleshed-out example of what a reducer might look like:

```javascript
import usersReducer from './usersReducer';
import blogPostsReducer from './blogPostsReducer';
import commentsReducer from './commentsReducer';
// ...

import { $$initialState as $$usersState } from './usersReducer';
import { $$initialState as $$blogPostsState } from './blogPostsReducer';
import { $$initialState as $$commentsState } from './commentsReducer';
// ...

export default {
  $$usersStore: usersReducer,
  $$blogPostsStore: blogPostsReducer,
  $$commentsStore: commentsReducer,
  // ...
};

export const initalStates = {
  $$usersState,
  $$blogPostsState,
  $$commentsState,
  // ...
};
```

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
react_on_rails-3.0.0.rc.1 docs/additional_reading/react-and-redux.md
react_on_rails-3.0.0.beta.1 docs/additional_reading/react-and-redux.md
react_on_rails-2.3.0 docs/additional_reading/react-and-redux.md
react_on_rails-2.2.0 docs/additional_reading/react-and-redux.md
react_on_rails-2.1.1 docs/additional_reading/react-and-redux.md
react_on_rails-2.1.0 docs/additional_reading/react-and-redux.md
react_on_rails-2.0.2 docs/additional_reading/react-and-redux.md
react_on_rails-2.0.1 docs/additional_reading/react-and-redux.md
react_on_rails-2.0.0 docs/additional_reading/react-and-redux.md
react_on_rails-2.0.0.rc.4 docs/additional_reading/react-and-redux.md
react_on_rails-2.0.0.rc.3 docs/additional_reading/react-and-redux.md
react_on_rails-1.2.2 docs/additional_reading/react-and-redux.md
react_on_rails-1.2.1 docs/additional_reading/react-and-redux.md
react_on_rails-2.0.0.rc.1 docs/additional_reading/react-and-redux.md
react_on_rails-2.0.0.beta.3 docs/additional_reading/react-and-redux.md
react_on_rails-2.0.0.beta.2 docs/additional_reading/react-and-redux.md
react_on_rails-1.2.0 docs/additional_reading/react-and-redux.md
react_on_rails-1.2.0.rc1 docs/additional_reading/react-and-redux.md
react_on_rails-1.1.1 docs/additional_reading/react-and-redux.md
react_on_rails-1.1.0 docs/additional_reading/react-and-redux.md