I'm using expo-router and need to pass some params back. How to do that?
I use router push here:
<TouchableOpacity style={styles.qrButton} onPress={()=> {router.push(`/rent-bike/qr-scanner`)}}>
<Text style={styles.qrText}>Użyj kodu QR</Text>
</TouchableOpacity>
Then I scan QR code and want to pass it back to display on same page:
const handleBarCodeScanned = ({type, data}) => {
setScanData(true)
console.log(`data: ${data}`);
console.log(`type: ${type}`);
router.back()
};
I can't see any solutions.