I have a question about browser refresh.
Since retool app is working on a browser, when I refresh the browser all the states are reset. This makes my page input all empty and I don't want to show this to users.
I wonder if there's a way to move to certain page when user refreshes the browser?
For example, if I'm on a article-detail page and refresh the browser I would like to move to article-list page.
Hey @Jaemoon_Lee - my general recommendation is to write a JS query that is set to run on page load and that redirects the user to your home page, as shown below.
The somewhat tricky part is figuring out what condition to use in the if conditional, as you obviously don't want to incorrectly redirect your users. Is there a state variable or something similar that you can reference?
I was able to solve it in a different way. Instead of the method you suggested, I used searchParams so that when the browser is refreshed, the URL’s searchParams are referenced and the corresponding data is fetched again through the datasource query.
This way, even after refreshing the browser, there’s no need to redirect to a specific page anymore.