Files
react-native/Libraries
Logan Daniels c46ca60e3f Make FlatList's renderItem return React.Node
Summary:
Flow typing can be annoying because the `renderItem` prop for FlatList always has to specifically be of type `React.Element`.

Since really we just want to return something renderable, it should be fine to type this as `React.Node` instead.

I'm not sure if this is valid, but it seems like since we just need to implant the `key` property, we should be able to accomplish this with a `React.Fragment` wrapper instead of needing to call `cloneElement`. Looking for feedback on if this is a sensible fix.

Changelog:
[General][Changed] Updated FlatList's renderItem Flow type from React.Element<any> to React.Node

Reviewed By: sahrens

Differential Revision: D14814805

fbshipit-source-id: ce6793dea5a92619babe048dcfddee0e4519979c
2019-04-08 12:55:09 -07:00
..
2019-03-14 07:00:27 -07:00
2018-12-11 20:01:00 -08:00
2019-04-04 10:53:34 -07:00
2019-03-14 07:00:27 -07:00
2019-01-17 02:41:59 -08:00
2019-04-08 09:15:14 -07:00
2018-10-31 01:37:26 -07:00
2019-03-19 10:24:52 -07:00
2019-04-04 10:53:34 -07:00
2019-03-14 07:00:27 -07:00