npm.io
1.0.1 • Published 7 years ago

react-native-scrollable-with-collapsable-header

Licence
Apache 2.0
Version
1.0.1
Deps
1
Size
14 kB
Vulns
0
Weekly
0
Stars
5
DeprecatedThis package is deprecated

react-native-scrollable-with-collapsable-header

What is it?

A simple react-native component to associate a collapsable header to any scrollable component (ie: ScrollView, FlatList, SectionList).

Usage

  <ScrollableWithCollapsableHeader 
    headerComponent={() => {
      <MyHeaderComponent />
    }}
    headerHeight={50}
    listComponent={({style, onScroll, scrollEventThrottle}) => {
      <ScrollView style={style}, onScroll={onScroll}, scrollEventThrottle={scrollEventThrottle} />
    }}
  />

Keywords