Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tabbar icon cannot class? #2085

Closed
shiqian123 opened this issue Jul 21, 2017 · 1 comment
Closed

tabbar icon cannot class? #2085

shiqian123 opened this issue Jul 21, 2017 · 1 comment

Comments

@shiqian123
Copy link

shiqian123 commented Jul 21, 2017

in v3
class TabIcon extends Component {}
<Scene key="home" icon={TabIcon}> <Scene key="homePage" component={HomePage}/> </Scene>
but in v4 this is error .I mast write that
const TabIcon = ()=>{}
<Scene key="home" icon={TabIcon}> <Scene key="homePage" component={HomePage}/> </Scene>

@aksonov
Copy link
Owner

aksonov commented Jul 21, 2017

Yes, it is limitation of React Navigation and it makes sense. Please use pure functions for icons.

@aksonov aksonov closed this as completed Jul 21, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants