-
Notifications
You must be signed in to change notification settings - Fork 25k
Description
Is this a bug report?
Depends on whether this is intended behavior.
Have you read the Contributing Guidelines?
Yes.
Environment
Environment:
OS: macOS High Sierra 10.13.3
Node: 9.4.0
Yarn: 1.3.2
npm: 5.6.0
Watchman: 4.9.0
Xcode: Xcode 9.2 Build version 9C40b
Android Studio: 3.0 AI-171.4443003
Packages: (wanted => installed)
react: 16.2.0 => 16.2.0
react-native: ^0.53.0 => 0.53.0
Target Platform: iOS (11.2)
Steps to Reproduce
- Create a
SectionList - Add a
ListHeaderComponentto theSectionList
Expected Behavior
The ListHeaderComponent would initially be hidden, and would only be revealed by scrolling up, similar to a search or filter bar on iOS. Scrolling to the top of the list (for example by tapping the status bar) would scroll to the top of the first item in the list, not to the top of the header component.
Actual Behavior
The ListHeaderComponent is rendered as if it were the first item in the list, and tapping the status bar scrolls to the top of the header component. I assume this is not the intended behavior, since the same can be achieved by using a different section on top of the list view with its own renderItem function. If the ListHeaderComponent is implemented the way I expected, it would make it much easier to implement custom search bars, filter bars, and the like.