上一页 1 ··· 221 222 223 224 225 226 227 228 229 ··· 498 下一页
只有注册用户登录后才能阅读该文。 阅读全文
posted @ 2020-01-19 02:53 Zhentiw 阅读(9) 评论(0) 推荐(0)
摘要: While it's powerful enough to have Machine.transition, it can get tedious constantly passing it a state and an event. It would be nice if we had a fun 阅读全文
posted @ 2020-01-18 22:45 Zhentiw 阅读(157) 评论(0) 推荐(0)
摘要: numerating the possible states of a function is a sound way to write a function, but it is imperative and could benefit from abstraction. We can do th 阅读全文
posted @ 2020-01-18 17:35 Zhentiw 阅读(173) 评论(0) 推荐(0)
摘要: There are several fundamental problems with trying to manage the state of a function through the use of booleans. The first is often referred to as "b 阅读全文
posted @ 2020-01-18 17:11 Zhentiw 阅读(374) 评论(0) 推荐(0)
摘要: Fire and Forgot: Fire an action and not wait it complete. Fire and Wait: FIre an action and wait for result. Fire and Forgot Fire and Wait: Using `mer 阅读全文
posted @ 2020-01-17 15:55 Zhentiw 阅读(429) 评论(0) 推荐(0)
摘要: Problem: Two ways to solve the problem: 1. Change the order: 2. Using createSelector: 阅读全文
posted @ 2020-01-16 18:37 Zhentiw 阅读(173) 评论(0) 推荐(0)
摘要: When defining a selector, you can also pass other selectors into the signature of the Selector decorator to join other selectors with this state selec 阅读全文
posted @ 2020-01-16 18:31 Zhentiw 阅读(262) 评论(0) 推荐(0)
摘要: 1. Selet piece of state from Store: This is useful when you just want to get state from the store directly. Of course that global state should contain 阅读全文
posted @ 2020-01-16 18:25 Zhentiw 阅读(350) 评论(0) 推荐(0)
摘要: This approach can also allow for the creation of well named helper functions that can be shared between handlers that require the same type of update. 阅读全文
posted @ 2020-01-16 17:07 Zhentiw 阅读(202) 评论(0) 推荐(0)
摘要: In general, it is not recommeded to use Namespace in Typescript, we should use ES6 module export import syntax. But there are still some good usecases 阅读全文
posted @ 2020-01-16 16:58 Zhentiw 阅读(170) 评论(0) 推荐(0)
上一页 1 ··· 221 222 223 224 225 226 227 228 229 ··· 498 下一页