FreeTubeApp / FreeTubeApp/FreeTube
[Feature Request]: Browser-esque back/forward cache (bfcache)
- Dominant language
- Vue
- Stars
- 21.9k
- Forks
- 1.5k
- Avg merge
- 1d 15h
- Merged PRs (30d)
- 62
Description
### Guidelines
- [X] I have searched the issue tracker for [open](https://github.com/FreeTubeApp/FreeTube/issues?q=is%3Aopen+is%3Aissue) and [closed](https://github.com/FreeTubeApp/FreeTube/issues?q=is%3Aissue+is%3Aclosed) issues that are similar to the feature request I want to file, without success.
- [X] I have searched the [documentation](https://docs.freetubeapp.io/) for information that matches the description of the feature request I want to file, without success.
- [X] This issue contains only one feature request.
### Problem Description
When navigating through FreeTube as a user who likes to minimize requests to my API of choice, it can be quite irksome that the data retrieved from each request is so transient. This results in so many additional requests when using the forward and backward navigation arrows just to see data that was loaded from the server moments prior.
### Proposed Solution
In search browsers, when navigating forwards and backwards from using history navigation, an entire snapshot of the page is made that can be restored at will in a moment's notice. This is done through what's known as [a back/forward cache, or bfcache](https://web.dev/articles/bfcache).
My proposed solution is to implement the bfcache behavior in FreeTube when navigating through route history. This would be the default, non-toggleable behavior. This might be problematic for videos while FT's lack of a bfcache is being leveraged as a workaround to the problems that would be solved by #1005, so the `/watch` route may have to be exempted from this behavior, or behave slightly differently.
### Alternatives Considered
This may have to be an optional (enabled-by-default) feature if some people have gotten used to the old behavior and want to have it back. Alternatively, we can allow route refreshing through an app wide refresh button and/or shortcut that's less drastic than the app refresh of Ctrl+R, which has also been discussed in #1005.
### Issue Labels
ease of use improvement, new feature
### Additional Information
_No response_
Contributor guide
Assessment
This issue has not been assessed yet.