2017-03-08 91 views

回答

1

正確的方法是查看解僱與TouchableWithoutFeedback和調用Keyboard.dismiss()

import {Keyboard} from 'react-native' 

<TouchableWithoutFeedback onPress={Keyboard.dismiss}> 
    <View style={styles.container}> 
     <TextInput keyboardType='numeric'/> 
    </View> 
</TouchableWithoutFeedback> 
1

This幫我:

import { Keyboard } from 'react-native' 

// Hide that keyboard! 
Keyboard.dismiss();