体验新版 GitCode,发现更多精彩内容 >>
import React, {Component} from 'react'; import {View, Text, StyleSheet} from 'react-native'; class Analysis extends Component { constructor(props) { super(props); } render() { return ( <View style={{ display: this.props.show ? 'flex' : 'none', backgroundColor: '#F2E2CE', flex: 1, }}> <Text style={styles.text}>数据分析模块</Text> </View> ); } } const styles = StyleSheet.create({ container: { backgroundColor: '#F2E2CE', flex: 1, }, text: { fontSize: 50, fontWeight: 'bold', textAlign: 'center', }, }); export default Analysis;