上一页 1 ··· 194 195 196 197 198 199 200 201 202 ··· 491 下一页
摘要: const Box = x => ({ map: f => Box(f(x)), chain: f => f(x), fold: f => f(x), toString: () => `Box(${x})` }) // Exercise: Box // Goal: Refactor each exa 阅读全文
posted @ 2020-05-09 03:40 Zhentiw 阅读(135) 评论(0) 推荐(0)
摘要: As a beginner of React, might have the confuses with 'useMemo' and 'React.memo': 'useMemo': When using functional components in React we may run into 阅读全文
posted @ 2020-05-07 20:06 Zhentiw 阅读(339) 评论(0) 推荐(0)
该文被密码保护。 阅读全文
posted @ 2020-05-07 18:22 Zhentiw 阅读(0) 评论(0) 推荐(0)
摘要: For development, we'll be using a separate server address to reach our REST endpoints. In a production build, this will likely be a different address, 阅读全文
posted @ 2020-05-05 02:55 Zhentiw 阅读(178) 评论(0) 推荐(0)
摘要: In package.json file: "prepare": "npm run build", "postpublish": "git push --tags", "prepare": make sure we don't forget to run build before publish t 阅读全文
posted @ 2020-05-04 18:54 Zhentiw 阅读(172) 评论(0) 推荐(0)
摘要: It's always important to test your code, especially if you're open-sourcing it for others to use. In this video, we'll learn how to use react-hooks-te 阅读全文
posted @ 2020-05-04 18:47 Zhentiw 阅读(212) 评论(0) 推荐(0)
摘要: When you use a React Portal, much of your component can be rendered outside the main DOM tree. Let’s see how we can use utilities provided by React Te 阅读全文
posted @ 2020-05-04 02:10 Zhentiw 阅读(701) 评论(0) 推荐(0)
摘要: You can get a huge amount of confidence and coverage from integration tests that test an entire page, or even your entire app. Let’s write a test that 阅读全文
posted @ 2020-05-04 01:58 Zhentiw 阅读(327) 评论(0) 推荐(0)
摘要: Sometimes your react component may need to do some cleanup work in the return value from useEffect or useLayoutEffect, or the componentWillUnmount lif 阅读全文
posted @ 2020-05-04 01:36 Zhentiw 阅读(373) 评论(0) 推荐(0)
摘要: That setup function is pretty handy. Seems like a good opportunity for an abstraction. Well, we already have one! It’s called React Hooks Testing Libr 阅读全文
posted @ 2020-05-04 01:00 Zhentiw 阅读(294) 评论(0) 推荐(0)
上一页 1 ··· 194 195 196 197 198 199 200 201 202 ··· 491 下一页