随笔分类 - Redux
摘要:Sometimes we want to test our Redux reducers to make sure they work as expected. In this lesson we will walk through setting up some Redux reducer tes...
阅读全文
posted @ 2016-01-12 03:21
Zhentiw
摘要:When using Redux, we can test that our application state changes are working by testing that dispatching actions to the store creates our expected out...
阅读全文
posted @ 2016-01-11 17:06
Zhentiw
摘要:For example, current we have those todos:{ todos: [ { completed: true, id: 0, text: "Learn Redux"}, { completed: false, id: 1, text: "Go shoppi...
阅读全文
posted @ 2015-12-17 01:23
Zhentiw
摘要:In the previous lesson we created a reducer that can handle two actions, adding a new to-do, and toggling an existing to-do. Right now, the code to up...
阅读全文
posted @ 2015-12-02 02:32
Zhentiw
摘要:Learn how to implement toggling a todo in a todo list application reducer.let todo = (state = [], action) => { switch(action.type){ case 'ADD_IT...
阅读全文
posted @ 2015-12-02 02:18
Zhentiw