Isn’t this problem with the spread operator not something that Rich also highlighted in his latest talk? https://jaredforsyth.com/2017/11/12/advanced-reasonreact-hider-order-components/ > Higher Order Components work in JavaScript because, in spreading the props to the child, you can “pass through” any props that the HOC doesn’t care about, but the child needs. OCaml’s type system doesn’t give us a good way to express “this component accepts any props the child does but also these other props”.
Btw, I have no idea what class FetcherComponent<T>
means in JavaScript… Does it have static typing and generics now?
@borkdude it doesn't, this might be Flow or Typescript
Maybe it’s something specific that React itself adds as a syntax?
I don't think so, because Flow was developed at Facebook, no reason for them to have another gradual type system
JSX also has angly brackets 😉
Yes, why miss an occasion to overload some syntax :)