by bogidon · 5y ago · 0 comments
However the bfcache unsurprisingly causes edge cases in JS-heavy pages/SPAs, and a prevailing solution [2] is for the page to force a reload when it is restored from this cache rather than explicitly handling those edge cases, nullifying the optimization.
If you want full Side by side browsing mode:
Some part of it is extremely easy - to display ALL tabs side by side:
profile/chrome/userChrome.css :
tabpanels {
display: -moz-box !important;
}
tabpanels > notificationbox {
-moz-box-flex: 1;
border-width: 2px !important;
border:solid #888;
}
For the other part - to have only two panels, sibling is easy, otherwise you would need some JS to mark a tab as something like content-secondary and handle it (e.g. there was an extension last_selected_tab doing like this AFAIR) - as you have only: tabpanels > notificationbox > browser[type=content-primary]
(Just tested in Firefox 60.4.0.esr - newer versions may need some minor adjustements in CSS, toolkit.legacyUserProfileCustomizations.stylesheets preference set to true and probably some other fixes. In 2008 I had a Norton Commander 'clone' made in such incredibly simple way, ALL file and media formats preview (plugins), with a bit of custom code for nsIProtocolHandler, and nsIURIFixup fixes :) , kudos to archView extension by Pike/Solar Flare.)R.I.P. Firefox.
Again something that used to work in Firefox.
FWIW: I use Tree Style Tabs (or Sideberry) to see why I arrived at a page. Not exactly the thing specified here but it works today.
You're writing Google Docs? Good for you, you can use an SPA. You're writing a social networking site? That should be a regular HTML page, with a sprinkling of JS. Blog? HTML page. Issue tracker? HTML page.
Every site I've used that's been plain HTML and CSS, with maybe minor supplements in Javascript, is much nicer to use than any SPA. People claim they load faster, but I've never experienced that in practice - a plain HTML page loads in milliseconds, but downloading a giant gzip of Javascript and waiting for it to make a zillion API calls takes seconds.
GMail's HTML-only interface fully loads and renders in ~630ms for me. The SPA version takes 11.69 seconds.
lite.cnn.com loads in 287ms. CNN.com takes 4.25 seconds.
thin.npr.org loads in 112ms. NPR.org takes 1.47 seconds.
Need I go on? Even for the lightest one, NPR, if you assume loading an article on the SPA version is instantaneous, you'd need to load 14 articles to make up for the slowness of the initial SPA load. The others are all much worse. And this is with an adblocker enabled - this will only get worse with one disabled.
Using SPAs when they aren't strictly necessary is a great way to shoot your site's performance, usability, and accessibility in the foot. You can fix the usability and accessibility problems, but you need to devote substantial engineering resources to doing so, and those are free if you just use the damn plain HTML.
Literally every other type of website on the planet should use traditional loading pages.