EvanBacon / expo-router-top-tabs

experimental
MIT License
50 stars 10 forks source link

Cannot read property 'setPage' of undefined. #9

Open Drish-xD opened 1 year ago

Drish-xD commented 1 year ago

@EvanBacon

Expo: v49, expo-router: v2

I m using this toptabs in my _layout.tsx

export default function TabLayout() {
  return (
    <TopTabs>
      <TopTabs.Header>
          <H3 pointerEvents="none">Hi</H3>
      </TopTabs.Header>
      <TopTabs.Screen name="index" options={{ title: "Home" }} />
      <TopTabs.Screen name="Chat" options={{ title: "Chat" }} />
    </TopTabs>
  );
}

Swipe is working fine, routes are changing but when i click on any tab, it showing this error.

image

Nareshj7 commented 8 months ago

Same issue. But works well in iOS.

Nareshj7 commented 8 months ago

By installing "react-native-tab-view" and "react-native-pager-view," I was able to resolve this error.