# FAQ

## Table of Contents

* **General**
  * [When should I learn Redux?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/General.md#general-when-to-learn)
  * [When should I use Redux?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/General.md#general-when-to-use)
  * [Can Redux only be used with React?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/General.md#general-only-react)
  * [Do I need to have a particular build tool to use Redux?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/General.md#general-build-tools)
* **Reducers**
  * [How do I share state between two reducers? Do I have to use combineReducers?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/Reducers.md#reducers-share-state)
  * [Do I have to use the switch statement to handle actions?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/Reducers.md#reducers-use-switch)
* **Organizing State**
  * [Do I have to put all my state into Redux? Should I ever use React's setState()?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/OrganizingState.md#organizing-state-only-redux-state)
  * [Can I put functions, promises, or other non-serializable items in my store state?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/OrganizingState.md#organizing-state-non-serializable)
  * [How do I organize nested or duplicate data in my state?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/OrganizingState.md#organizing-state-nested-data)
* **Store Setup**
  * [Can or should I create multiple stores? Can I import my store directly, and use it in components myself?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/StoreSetup.md#store-setup-multiple-stores)
  * [Is it OK to have more than one middleware chain in my store enhancer? What is the difference between next and dispatch in a middleware function?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/StoreSetup.md#store-setup-middleware-chains)
  * [How do I subscribe to only a portion of the state? Can I get the dispatched action as part of the subscription?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/StoreSetup.md#store-setup-subscriptions)
* **Actions**
  * [Why should type be a string, or at least serializable? Why should my action types be constants?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/Actions.md#actions-string-constants)
  * [Is there always a one-to-one mapping between reducers and actions?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/Actions.md#actions-reducer-mappings)
  * [How can I represent “side effects” such as AJAX calls? Why do we need things like “action creators”, “thunks”, and “middleware” to do async behavior?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/Actions.md#actions-side-effects)
  * [Should I dispatch multiple actions in a row from one action creator?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/Actions.md#actions-multiple-actions)
* **Immutable Data**
  * [What are the benefits of Immutability?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/ImmutableData.md#benefits-of-immutability)
  * [Why is immutability required in Redux?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/ImmutableData.md#why-is-immutability-required)
  * [Do I have to use Immutable.JS?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/ImmutableData.md#do-i-have-to-use-immutable-js)
  * [What are the issues with using ES6 for immutable operations?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/ImmutableData.md#issues-with-es6-for-immutable-ops)
* **Using Immutable.JS with Redux**
  * [Why should I use an immutable-focused library such as Immutable.JS?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/recipes/UsingImmutableJS.md#why-use-immutable-library)
  * [Why should I choose Immutable.JS as an immutable library?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/recipes/UsingImmutableJS.md#why-choose-immutable-js)
  * [What are the issues with using Immutable.JS?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/recipes/UsingImmutableJS.md#issues-with-immutable-js)
  * [Is Immutable.JS worth the effort?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/recipes/UsingImmutableJS.md#is-immutable-js-worth-effort)
  * [What are some opinionated Best Practices for using Immutable.JS with Redux?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/recipes/UsingImmutableJS.md#immutable-js-best-practices)
* **Code Structure**
  * [What should my file structure look like? How should I group my action creators and reducers in my project? Where should my selectors go?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/CodeStructure.md#structure-file-structure)
  * [How should I split my logic between reducers and action creators? Where should my “business logic” go?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/CodeStructure.md#structure-business-logic)
  * [Why should I use action creators?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/CodeStructure.md#structure-action-creators)
* **Performance**
  * [How well does Redux “scale” in terms of performance and architecture?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/Performance.md#performance-scaling)
  * [Won't calling “all my reducers” for each action be slow?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/Performance.md#performance-all-reducers)
  * [Do I have to deep-clone my state in a reducer? Isn't copying my state going to be slow?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/Performance.md#performance-clone-state)
  * [How can I reduce the number of store update events?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/Performance.md#performance-update-events)
  * [Will having “one state tree” cause memory problems? Will dispatching many actions take up memory?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/Performance.md#performance-state-memory)
  * [Will caching remote data cause memory problems?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/Performance.md#performance-cache-memory)
* **Design Decisions**
  * [Why doesn't Redux pass the state and action to subscribers?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/DesignDecisions.md#does-not-pass-state-action-to-subscribers)
  * [Why doesn't Redux support using classes for actions and reducers?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/DesignDecisions.md#does-not-support-classes)
  * [Why does the middleware signature use currying?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/DesignDecisions.md#why-currying)
  * [Why does applyMiddleware use a closure for dispatch?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/DesignDecisions.md#closure-dispatch)
  * [Why doesn't `combineReducers` include a third argument with the entire state when it calls each reducer?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/DesignDecisions.md#combineReducers-limitations)
  * [Why doesn't `mapDispatchToProps` allow use of return values from `getState()` or `mapStateToProps()`?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/DesignDecisions.md#no-asynch-in-mapDispatchToProps)
* **React Redux**
  * [Why isn't my component re-rendering, or my mapStateToProps running?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/ReactRedux.md#react-not-rerendering)
  * [Why is my component re-rendering too often?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/ReactRedux.md#react-rendering-too-often)
  * [How can I speed up my mapStateToProps?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/ReactRedux.md#react-mapstate-speed)
  * [Why don't I have this.props.dispatch available in my connected component?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/ReactRedux.md#react-props-dispatch)
  * [Should I only connect my top component, or can I connect multiple components in my tree?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/ReactRedux.md#react-multiple-components)
* **Miscellaneous**
  * [Are there any larger, “real” Redux projects?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/Miscellaneous.md#miscellaneous-real-projects)
  * [How can I implement authentication in Redux?](https://github.com/deminoth/redux/tree/8408d9e92889ac07e5fd14f937e56cb189010cf9/docs/faq/Miscellaneous.md#miscellaneous-authentication)
