Skip to content

Commit bee33a4

Browse files
nmnfacebook-github-bot
authored andcommitted
Improve Flow Types
Differential Revision: D5963184 fbshipit-source-id: 206f0d52b66f4f1af284445b10a8a4ff7b2cc36d
1 parent 2d2dfa2 commit bee33a4

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

Libraries/Lists/SectionList.js

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ import type {Props as VirtualizedSectionListProps} from 'VirtualizedSectionList'
2323

2424
type Item = any;
2525

26-
type SectionBase<SectionItemT> = {
26+
export type SectionBase<SectionItemT> = {
2727
/**
2828
* The data for rendering items in this section.
2929
*/
@@ -187,10 +187,11 @@ type OptionalProps<SectionT: SectionBase<any>> = {
187187
legacyImplementation?: ?boolean,
188188
};
189189

190-
export type Props<SectionT> = RequiredProps<SectionT> &
191-
OptionalProps<SectionT> &
192-
VirtualizedSectionListProps<SectionT>;
193-
190+
export type Props<SectionT> = {
191+
...$Exact<RequiredProps<SectionT>>,
192+
...$Exact<OptionalProps<SectionT>>,
193+
...$Exact<VirtualizedSectionListProps<SectionT>>,
194+
};
194195
const defaultProps = {
195196
...VirtualizedSectionList.defaultProps,
196197
stickySectionHeadersEnabled: Platform.OS === 'ios',

0 commit comments

Comments
 (0)