스크롤 다운 화면 만들시 상단 view 고정 시켜야하는데 보통 stickyHeaderIndices={ [ number ] } 로 고정시킨다.

다만 ScrollView에서 stickyHeaderIndices로 고정하면서 Animated.View로 height, ... 애니메이션 효과 주려할때 

'stickyHeaderIndices style property height is not supported by native animated module' 에러가 발생하면서 애니메이션 효과를 줄수가 없다.

솔루션 코드는 여기에 있다. - https://gist.github.com/BoBinLee/76f13317e135adc16a7eae42fe4aab7e

해결방법은 간단하다.

View를 한번더 감싸고 감싼 View style={{ height: 1 }}을 주면 끝.

원하는 방식대로 동작하는 것을 확인할 수 있다.

설정

트랙백

댓글