react native RadioGroup RadioButton 如何默认选中一个



  • 29 <RadioGroup
    30 onSelect = {(index, value) => this.onSelect(index, value)}
    31 >
    32 <RadioButton value={'item1'} >
    33 <Text>This is item #1</Text>
    34 </RadioButton>
    35
    36 <RadioButton value={'item2'}>
    37 <Text>This is item #2</Text>
    38 </RadioButton>
    39
    40 <RadioButton value={'item3'}>
    41 <Text>This is item #3</Text>
    42 </RadioButton>
    43
    44 </RadioGroup>
    45

    63 module.exports = App


登录后回复