> git clone https://github.com/StephenGrider/ReduxSimpleStarter.git
> cd ReduxSimpleStarter
> npm install
> npm start
- Create a diagram for all the different routes and its views.
- Determine the components to be used in each view.
- Determine the definition of a component.
- Determine the Redux state for our app. In this case it will only
contain one property 'posts' containing a list of all the posts. We
won't require a property like 'activePost' because it will be implicitly stated by the route itself( /posts/:id ). - Create your first action creater. In this case it is fetchPosts() which fetches our particular selected post from the api and sends it to reducer.
- Create your first reducer reducer_posts for action FETCH_POSTS which redcues the received posts data array into object form {1:{post1}, 2:{post2}, 3:{post3}} using loadsh mapKeys(arrayName, '<YOUR_KEY>') function.
- Integrating our with FETCH_POSTS action using connect in a shortcut way.
- Call the fetchPosts() action creator from inside component.
- Display the posts as list inside the component.
- Scaffold PostsNew component and add route configuration.
- Add navigation between Index(/) and New(/posts/new).
- Make action creator to save post.
- To handle the form input and its validation we will use redux-form(https://redux-form.com/).