This is another victim of the change to capabilities.
What’s the new best way to load a specific discovery route as homepage depending on device type?
This is another victim of the change to capabilities.
What’s the new best way to load a specific discovery route as homepage depending on device type?
What @merefield said ![]()
Since this component has been marked broken, I put together a replacement that works with current Discourse versions: Mobile Latest Homepage
It avoids the deprecated site.mobileView entirely, using window.matchMedia for viewport detection and Ember’s service:router for the redirect. It also remembers the user’s last choice between Latest and Categories for the duration of their session, so navigating back to the homepage respects their preference.
Tested on iPhone (lands on Latest), iPad landscape (two-column Categories+Latest unchanged), and desktop (unchanged).
great stuff … but really, in a perfect world we shouldn’t have to be loading one route and redirecting to another.
this is a layout issue now, not a route issue.
Instead, the approach I’ve been experimenting with is add a Categories column in a Bars left sidebar on Latest, which is absent on mobile.
So you load Latest on both devices, but the Categories column is simply missing on mobile ![]()
the solution is open source, but a bit unfinished and not documented. If you take a look at my github account, you might be able to find the pieces ![]()