摘要: Shuffling is a common process used with randomizing the order for a deck of cards. The key property for a perfect shuffle is that each item should hav 阅读全文
posted @ 2019-01-29 19:59 Zhentiw 阅读(291) 评论(0) 推荐(0)
摘要: The DOM can be a bit tricky when it comes to typing. You never really know exactly what you're going to get, so you have to educate your codebase into 阅读全文
posted @ 2019-01-29 19:14 Zhentiw 阅读(582) 评论(0) 推荐(1)
摘要: TypeScript can help you with your plain JavaScript files if you add a simple //@ts-check comment. Then you can enhance the experience by add proper JS 阅读全文
posted @ 2019-01-29 19:04 Zhentiw 阅读(404) 评论(0) 推荐(0)
摘要: 1. ngOnChanges is called before ngOnInit but after constructor() 2. ngOnChanges is called because of @Input() obj, obj's reference changes. If you mut 阅读全文
posted @ 2019-01-29 18:56 Zhentiw 阅读(190) 评论(0) 推荐(0)
摘要: Recentlly, I am learning crocks.js ADT libaray. In the beginning, it is hard to understand when to use 'runWith', 'evalWith', 'execWith'. Until I went 阅读全文
posted @ 2019-01-29 17:22 Zhentiw 阅读(219) 评论(0) 推荐(0)
摘要: Using put to update our state for a given state transaction can make it difficult to modify a given state based on its previous value. In this lesson 阅读全文
posted @ 2019-01-29 17:13 Zhentiw 阅读(144) 评论(0) 推荐(0)
摘要: Stateful computations require the ability for their state to change overtime. We take a look on one way to replace the state portion of our stateful d 阅读全文
posted @ 2019-01-29 16:36 Zhentiw 阅读(196) 评论(0) 推荐(0)
摘要: We take a closer look at the get construction helper and see how we can use it to lift a function that maps the state portion and updates the resultan 阅读全文
posted @ 2019-01-29 16:15 Zhentiw 阅读(150) 评论(0) 推荐(0)
摘要: We explore our first stateful transaction, by devising a means to echo our state value into the resultant for independent modification. With our state 阅读全文
posted @ 2019-01-29 01:10 Zhentiw 阅读(165) 评论(0) 推荐(0)