Facing a wierd problem. I have exported my app to APK and installed it on my phone.
In my app there’s a logic that if the user log’s out, he should be linked to the login page. This is working fine. But when I press the android’s back button, it takes me to the previous screen and shows no data (because the user is logged out)
I understand this can happen on a PWA, but why is it happening in the native app and how to solve this ?
I believe there’s a component that disables Android’s back button.
I believe you have one?
Yeah that’s true. This component will disable the back button on the screen where it’s added. And that’s would solve your problem you can find it here
Https://jimmynoujaim.com/adalo
Hey there @Nitish
I would highly recommend getting that plugin that @njimmy10 created.
However, I have come up with an alternate method.
You can add a blank screen and name it “Logged Out” with a white background. Add text that says “You are logged out” (or you can leave it blank so it just kinda looks like the page refreshes).
Add an action when a user visits this logged out screen to link to the welcome/signup/login screen (whichever you prefer to send them to).
On your logout action, link to the new logged out screen.
That’ll prevent users from going back into the app after logging out.
Thanks @njimmy10 I’ll check this out
Hey @Flawless, that sounds logical. I will test this out
Hey @Flawless, I checked your method. It worked partially.
After logging out if the user presses back button once then this works, but if the user presses back button two or more times continuously, this doesn’t work. Even before Adalo loads the page, user is redirected to the previous screen