上一页 1 ··· 417 418 419 420 421 422 423 424 425 ··· 469 下一页
摘要: A common problem when dealing with some kinds of data is that not every object has the same nested structure. lukeskywalker.parents.father.isjedi work... 阅读全文
posted @ 2016-01-14 03:19 Zhentiw 阅读(165) 评论(0) 推荐(0) 编辑
摘要: Map is really useful when you want to use object as a key to set vaule, in ES5, you cannot really use object as a key:var user1 = { name: "Wan", age... 阅读全文
posted @ 2016-01-13 02:42 Zhentiw 阅读(356) 评论(0) 推荐(0) 编辑
摘要: /** * A reducer for a single todo * @param state * @param action * @returns {*} */const todo = ( state, action ) => { switch ( action.type ) { ... 阅读全文
posted @ 2016-01-12 19:49 Zhentiw 阅读(405) 评论(0) 推荐(0) 编辑
摘要: Learn how to create a React todo list application using the reducers we wrote before./** * A reducer for a single todo * @param state * @param action ... 阅读全文
posted @ 2016-01-12 18:11 Zhentiw 阅读(405) 评论(0) 推荐(0) 编辑
摘要: 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 阅读(230) 评论(0) 推荐(0) 编辑
摘要: 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 阅读(235) 评论(0) 推荐(0) 编辑
摘要: .blue{ color: blue}.bold{ font-weight: bold;}.large{ font-size: 40px;}ngClass can accept an array:ngClassngClass can take a string:ngClassngClas... 阅读全文
posted @ 2016-01-10 16:06 Zhentiw 阅读(174) 评论(0) 推荐(0) 编辑
摘要: When testing React components, we often want to make sure the rendered output of the component matches what we expect. With the React Shallow Renderer... 阅读全文
posted @ 2016-01-07 16:53 Zhentiw 阅读(194) 评论(0) 推荐(0) 编辑
摘要: Setting up a shallow renderer for each test can be redundant, especially when trying to write similar tests that have slight tweaks. In this lesson, w... 阅读全文
posted @ 2016-01-07 15:12 Zhentiw 阅读(172) 评论(0) 推荐(0) 编辑
摘要: Often our components have output that shows differently depending on the props it is given; in this lesson, we go over how to compare theclassNameprop... 阅读全文
posted @ 2016-01-07 03:52 Zhentiw 阅读(273) 评论(0) 推荐(0) 编辑
上一页 1 ··· 417 418 419 420 421 422 423 424 425 ··· 469 下一页