【发布时间】:2019-03-17 15:06:52
【问题描述】:
我的 package.json 版本 “世博会”:“^30.0.1” “本地基础”:“^2.8.1” “反应”:“16.3.1”, "react-native": "https://github.com/expo/react-native/archive/sdk-30.0.0.tar.gz"
当我尝试以下代码时应用程序冻结
<Tabs tabBarPosition="bottom" initialPage={1} locked onChangeTab={({ i }) => this.setState({ currentTab: i })}>
<Tab heading={<TabHeading>
<Icon name="bell" type='SimpleLineIcons' style={{fontSize:22}} />
<Text style={{color:(this.state.header == 'Snapshot'?Colors.themeBlue:'black')}}>Snapshot</Text>
</TabHeading>}
>
<Text> tab 1</Text>
</Tab>
<Tab heading={<TabHeading>
<Icon name="compass" type="SimpleLineIcons" style={{fontSize:22}} />
<Text style={{color:(this.state.header == 'Discover'?Colors.themeBlue:'black')}}>Discover</Text>
</TabHeading>} style={{backgroundColor:'#e8e8e8'}}
>
<Text> tab 2</Text>
</Tab>
</Tabs>
【问题讨论】:
标签: react-native