Closed boc-the-git closed 2 months ago
Hmm.. Interesting idea. I think what we'd actually need would be to have the podcast feed url in the slug. That way you could even send the url to someone else and they could open it directly because the needed context would be stored in the url itself. There's a few pages where F5 on them doesn't work currently actually, user_stats, settings, episode_layout, and podcasts page after searching are all examples. What's needed in most cases is a bit of browser storage so the info currently displayed is retained, but yeah, I think with the episode_layout page it'd be great if you could send someone a link directly to open that particular podcast on your instance of Pinepods. Sharing episode links is on the short term list as well so that's kind of in the same vein. I'll get to work on a solution for all these things asap!
Put quite a lot of effort into the implementation here. It now utilizes the url to support information and data for the podcast. Whether they are added to the db or not it works great, and you can share a link with others on the same server. They look like this for example: http://localhost:8080/episode_layout?podcast_title=Ship%20It%21%20SRE%2C%20Platform%20Engineering%2C%20DevOps&podcast_url=https%3A%2F%2Fchangelog.com%2Fshipit%2Ffeed
This also fixes refreshing on that page because it will load context from the url bar. At this point there's no pages in the entire app where refreshing will cause an issue. Everything retains user context and will reload the way that it was before. #241
My suggestion would be to store a slug or ID in the url, such that when viewing podcast XYZ, you aren't on URL
baseurl/episode_layout
but ratherbaseurl/episode_layout/xyz
, or something like that. That way a refresh can get the context of what podcast the page should be displaying.Tested with ctrl+r and ctrl+f5, with no noticeable difference in behaviour.