Open jimkhan opened 3 years ago
I'm using "react-native-fingerprint-scanner": "^6.0.0" it works fine on emulator. But when I built apk it taking too much time(3 or 4 seconds) to authenticate on a real device. What can I do?
Here is my code:
const SplashBeforeFingerprint = ({ navigation }) => { useEffect(() => { FingerprintScanner .authenticate({ description: 'Scan your fingerprint on the device scanner to continue' }) .then(() => { /// nothing to do }) .catch((error) => { Alert.alert( "Authentication failed", "Your fingerprint doesn't matches! Try agin later!", [ { text: "Exit", onPress: () => BackHandler.exitApp(), style: "cancel" }, ], { cancelable: false }); }); }, []); return ( <ImageBackground source={require("../img/Splash2.png")} style={styles.imageContainer} > <View style={styles.buttonContainer} > <AppButton style={styles.button} textStyle={styles.text} name={"Go to Home"} onPress={() => navigation.reset({ index: 2, routes: [{ name: 'NewWallet' }], })} /> </View> </ImageBackground> ) }
I'm using "react-native-fingerprint-scanner": "^6.0.0" it works fine on emulator. But when I built apk it taking too much time(3 or 4 seconds) to authenticate on a real device. What can I do?
Here is my code: