Motivation
Why reanimated-tab-view?
-
The original react-native-tab-view is an amazing package, no doubt. However, it is dependent on
react-native-pager-view. This dependency complicates solving issues such as:TabView tab index not really controlledTab label aligning vertically in some devices when render single tab.Screen getting stuck when switching between the tabs while keyboard opened.
reanimated-tab-view depends purely on react-native-reanimated, and as such, the above issues won't be encountered.
-
The swipe and jump-to behaviors are built from scratch using the animation and gesture primitives offered by react-native-reanimated and react-native-gesture-handler.
-
Many real apps like Instagram, X, Reddit and LinkedIn have tab views that support collapsible headers. The original react-native-tab-view doesn't provide this support. We consider it an anti-pattern for a tab view component to not have support for collapsible headers — so reanimated-tab-view has it built-in.