I am removing some values when app closes, and I am doing it with useEffect but it does not works.
export default RootComponent = ()=> {
useEffect(()=> {
return ()=> {
// on Android 10 Galaxy A60: this function never invoked, when app closes
// on Android 6 Galaxy note9 clone: this function invoked, when app closes
}
}, []);
return (
// ...
);
}