O'Reilly logo

React Native By Example by Richard Kho

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Creating the EditTask container

The EditTaskContainer will be composed the same way as TasksListContainer. It will do the following:

  1. Import actions relevant to the EditTask component from your actions file.
  2. Import the EditTask and connect module.
  3. Contain a mapDispatchToProps method to map the actions you imported.
  4. Call mapStateToProps on any parts of the Redux state you wish EditTask to have access to.
  5. Call connect on mapDispatchToProps, mapStateToProps, and the EditTask component.

These are the actions that EditTask will be utilizing:

 // TasksRedux/app/containers/EditTaskContainer import { connect } from 'react-redux'; import { changeSelectedTaskCompleted, changeSelectedTaskDueDate, editSelectedTaskName, expandCell, removeSelectedTaskDueDate, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required