Quantcast
Channel: Active questions tagged react-native+typescript - Stack Overflow
Viewing all articles
Browse latest Browse all 6287

Usage of function: goToPage() in TabbedHeaderPager

$
0
0

Im using TabbedHeaderPager in my project and i need to change tab programmatically and im trying to use function: goToPage() but i have problem to access the function.I have tried as a prop and through pagerProps.

<TabbedHeaderPager      goToPage={goToPage} // cant access function here      pagerProps={{         onScroll, //this function works        goToPage // cant access function here      }}          rememberTabScrollPosition      onTopReached={() => console.log('onTopReached')}      snapToEdge={false}      parallaxHeight={400}      backgroundColor={t.background.val}      title={club.name ? club.name : 'My Golf Club'}      foregroundImage={getClubLogoImage(club)}      containerStyle={{        minHeight: 800,      }}      backgroundImage={getClubBackgroundImage(club)}      tabs={tabs}>      {tabs.map((tab, index) => tab.content)}</TabbedHeaderPager> 

Viewing all articles
Browse latest Browse all 6287

Trending Articles