随笔分类 -  React

上一页 1 ··· 5 6 7 8 9 10 11 12 13 ··· 23 下一页
摘要:const [state, dispatch] = useReducer(reducer, initialArg, init); The third arguement 'init' is a lazy initialization which is a function. It is useful 阅读全文
posted @ 2020-03-10 16:35 Zhentiw 阅读(223) 评论(0) 推荐(0)
摘要:As a user, it can be very disorienting when the "wrong" UI is briefly shown to the user: a login link is shown to an authenticated user, or a 404 erro 阅读全文
posted @ 2020-03-08 04:02 Zhentiw 阅读(103) 评论(0) 推荐(0)
只有注册用户登录后才能阅读该文。
posted @ 2020-01-15 04:10 Zhentiw 阅读(1) 评论(0) 推荐(0)
只有注册用户登录后才能阅读该文。
posted @ 2019-12-20 04:16 Zhentiw 阅读(2) 评论(0) 推荐(0)
只有注册用户登录后才能阅读该文。
posted @ 2019-12-19 03:46 Zhentiw 阅读(1) 评论(0) 推荐(0)
只有注册用户登录后才能阅读该文。
posted @ 2019-12-19 03:30 Zhentiw 阅读(2) 评论(0) 推荐(0)
只有注册用户登录后才能阅读该文。
posted @ 2019-12-16 01:48 Zhentiw 阅读(2) 评论(0) 推荐(0)
摘要:In this lesson we'll see an interesting situation where we're actually calling a function component and getting a dreaded React error: "Rendered fewer 阅读全文
posted @ 2019-12-12 17:14 Zhentiw 阅读(1224) 评论(0) 推荐(0)
摘要:Based on research at Facebook, we know that if a user sees a flash of loading state, they perceive the app as being slower. So let's improve the pendi 阅读全文
posted @ 2019-12-10 15:49 Zhentiw 阅读(225) 评论(0) 推荐(0)
只有注册用户登录后才能阅读该文。
posted @ 2019-12-10 02:51 Zhentiw 阅读(2) 评论(0) 推荐(0)
只有注册用户登录后才能阅读该文。
posted @ 2019-12-10 01:27 Zhentiw 阅读(1) 评论(0) 推荐(0)
只有注册用户登录后才能阅读该文。
posted @ 2019-12-10 01:23 Zhentiw 阅读(1) 评论(0) 推荐(0)
摘要:Using Suspense within our component isn't exactly ergonomic. Let's put all that logic into a reusable function so we can create resources anytime we n 阅读全文
posted @ 2019-12-08 18:18 Zhentiw 阅读(204) 评论(0) 推荐(0)
摘要:Let's get started with the simplest version of data fetching with React Suspense. It may feel a little awkward, but I promise you that you wont be wri 阅读全文
posted @ 2019-12-08 17:52 Zhentiw 阅读(548) 评论(0) 推荐(0)
只有注册用户登录后才能阅读该文。
posted @ 2019-12-08 04:02 Zhentiw 阅读(1) 评论(0) 推荐(0)
只有注册用户登录后才能阅读该文。
posted @ 2019-12-04 03:28 Zhentiw 阅读(1) 评论(0) 推荐(0)
只有注册用户登录后才能阅读该文。
posted @ 2019-12-04 03:21 Zhentiw 阅读(2) 评论(0) 推荐(0)
摘要:Before we publish our package, we want to make sure everything is set up correctly. We’ll cover versioning, preparing our package, adding a proper REA 阅读全文
posted @ 2019-11-04 16:54 Zhentiw 阅读(189) 评论(0) 推荐(0)
摘要:Similar to writing a custom State Hook, we’ll write our own Effect Hook called useStarWarsQuote, which returns a random quote and a loading state. Rem 阅读全文
posted @ 2019-11-01 20:22 Zhentiw 阅读(250) 评论(0) 推荐(0)
摘要:Writing your own custom State Hook is not as a daunting as you think. To keep things simple, we'll refactor our text state value that uses useState an 阅读全文
posted @ 2019-10-31 20:56 Zhentiw 阅读(194) 评论(0) 推荐(0)

上一页 1 ··· 5 6 7 8 9 10 11 12 13 ··· 23 下一页