Reactjs 证明我的卡中的内容不起作用

Reactjs 证明我的卡中的内容不起作用,reactjs,react-native,flexbox,jsx,Reactjs,React Native,Flexbox,Jsx,我希望我的内容在中间..顶部和底部的边距相等,所以我使用justifyContent='center',但什么都没有发生 <View style={styles.allAttendeesContainer}> <Image style={styles.imageSpeaker} source={{ uri: item.image

我希望我的内容在中间..顶部和底部的边距相等,所以我使用justifyContent='center',但什么都没有发生

              <View style={styles.allAttendeesContainer}>
              <Image
              style={styles.imageSpeaker}
              source={{
                uri: item.image
              }}/>
              <View>
              <Text style={[styles.textSpeakerDetail,{fontWeight:'bold',color:'#000'}]}>Muthu Ramalingam</Text>
              <Text style={styles.textSpeakerDetail}>HelloLead,DexPatent</Text>
              <Text style={styles.textSpeakerDetail}>Information Technology and Services</Text>
              </View>
              </View>
你还没用过吗

对齐项目:“中心”

像这样

allAttendeesContainer: {
height: 125,
flexDirection: 'row',
borderBottomWidth: 0.5,
flex: 1,
justifyContent: 'center',
alignItems: 'center',
},
allAttendeesContainer: {
height: 125,
flexDirection: 'row',
borderBottomWidth: 0.5,
flex: 1,
justifyContent: 'center',
alignItems: 'center',
},