- React
- ReactiveConf
- 2018
- Typed HOCs with Flow
Typed HOCs with Flow
Luis Roman at ReactiveConf 2018
Composition over inheritance is one of the recommended patterns in OOP and in functional programming is just how things work by default. So when using React we work by composing components together to build a whole App and the more we can extract common behavior the more re-usable our code is, this is where Higher Order Components come into play. We’ll quickly cover some of its basics and benefits of Higher Order Components and then jump into how we can type them with Flow for better developer experience.