Make HTML documents work with adblock, noscript, request policy, ghostery, jsoff, without js and on their own
I was thinking,

A lot of people use browser extensions that block advertisements, scripts, cross site requests, redirects, etc

retro futurism is the new hip

In the old days when Internet Exploder was even more awful developers went out of their way to support the poor excuse for a web browser. Some would go as far as to trim down the feature set to a sub set that could be made to work in any browser(internet exploder) People wrote libraries to account for the lack of out of the box features. Kicking and screaming the Internet Exploder was dragged into the 21th century. I honestly thought it was a most stupid idea to have software account for malformed outdated platforms. To me that sounded like it could only happen at the expense of the rest of development. Later I came to see that with all this encouragement we get a stubborn people who will continue to try to load your web application in internet explorer. For that reason it was not unreasonable to add a few extra lines so that their stupidity can be ignored. Eventually, I now see it is a much better idea to just add the whole library of hacks and avoid the debate about peoples stupidity all together. It is a much better idea to secretly patch peoples cluelessness and to proverbially giggle about it behind their back. If you are the one who can do it, that makes you responsible, you decide if people are to look stupid. We cant have the illusions of productivity if one chooses to make others look silly. Making people look silly will draw away time and attention from the rest of development.

the issues

So lets say people use :

Adblock Plus by Wladimir Palant
https://addons.mozilla.org/en-US/firefox/addon/adblock-plus/

NoScript Security by Giorgio Maone
https://addons.mozilla.org/en-US/firefox/addon/noscript/

RequestPolicy by Justin Samuel
https://addons.mozilla.org/en-US/firefox/addon/requestpolicy/

Ghostery by Felix Shnir, José María Signanini
https://addons.mozilla.org/en-US/firefox/addon/ghostery/

JSOff by Bowen Li
https://addons.mozilla.org/en-us/firefox/addon/jsoff/

Each will allow one to visit ever greater numbers of websites. All these things are there for a reason of course so the end result will be increasingly crappy

Web pages making 70 requests are not unusual, if you reduce that number to 1 (counting the page it self) you can open 70 pages in the same time you could normally open 1.

3 or 4 pages with everything on them could be as much load as 200 pages without anything.

It isn't unusual to have some support for browsers without js but what if the user decides not to load your 37 style sheets? Lets say for the sake of argument, he or she isn't going to load any of your external content.

Websites often have 1,2 or 3 long menus on the side and a bit of content in the middle having roughly equal length. If you remove the css entirely it isn't unusual for the menues to be positioned above the content. If you are lucky or a SEO master you just have content at the top with the menues under it. But then the user still doesn't get to use the menus.

More often the style sheet is hosted on the same domain and the website just works wonderfully.

But if we add a tiny bit of inline css in the html document and/or a tiny bit of js.

The whole div positioning scheme is perhaps 3 lines long, giving it some minimalistic style doesn't take a lot of lines. It doesn't have to be supper pretty, as long as the page is still usable.

<style>

body{background:#345;color:black}
div{background:#fff;float:left;width:94%;padding:2%;margin:1%;}
#menuDivOne {width:10%}
#contentDiv {width:78%}
#headerContent {background-color:#ABC;border:3px solid yellow;}
.shown{display:inline;}
.hidden{display:none;}

</style>

Non of it is !important, it goes above the external css file in the html document so that loading matching entries from the external file overrides these styles.

The most minimalistic javascript feature set is probably hiding and showing elements. Requesting a whole page from the backend for that takes much to long, it would be nice if it just worked.

<script> toggle=function(x){x.className=(x.className=="hidden")?"show":"hidden";} </script>

If that also doesn't work we just fold open all the hidden toggles.

<noscript><style>.foo{display:inline !important}</style></noscript> that unfolds all the fold outs.

It then becomes possible to save the html document to disk and have a reasonably usable page.

There is nothing guaranteed about anything hosted or linked on a website. If the html document can function on it's own the rest of the components are not required. Not that it isn't nice to have the whole website of course. We just want to prevent (now our) failure from further escalating.

How much extra weight does it add to do something like this?

<img src="http://example.com/img.jpg" data-x="0" onerror="a=['http://example.com/img.jpg','http:/example.com/img2.jpg','http://img.go-here.nl/michael-faraday.jpg'];this.src=a[this.dataset.x++]" >



It seems to me that if you add enough extra mirrors the total code isn't much more than the list of mirrors it self.

The image can even be made to always work!

<img src="http://example.com/img.jpg" data-x="0" onerror="a=['http://example.com/img.jpg','http:/example.com/img2.jpg','http://example.com/michael-faraday.jpg',this.dataset.uri];this.src=a[this.dataset.x++]" style="width:290px;" data-uri='data:image/gif,GIF89a%1D%00%24%00%B3%00%00%08%03%05%E3%96UlH%3DN.%26%C7%B9%B3%7C_XW%17%07%ED%C3%8D%F9%E4%B8%A2%8B%86%C8l6%F7%F7%F4%8Dsk%915%10%C0%A4%93%AAS%26%21%F9%04%00%00%00%00%00%2C%00%00%00%00%1D%00%24%00%03%04%FF%10%C8I%AB%BD%18%8C%92%5C%2A%80%91%8D%80%40%2C%E8%92%0C%0C%91%08%245%0CI%8A8Eq%A2x%BC%255%14%81pp%ECP%88%C4H4%10%08%16%AE%C0%01%818%1C%8E%04FFd%98%11%06%8D%00uQ-%08%10P%87v90%18%14V%2AU%A1p%19%B31%40%03%5E%AD%06%149N%0C%0C%031%06%0F%01%0BES%08%01%0F%06%02M%09"%24n%87%0D%0D%88%01%8E3%90%83%94%86%0D%14%06%0Dn%25%1By%12%03%01%A6%21%0A%5D%12%A0K%A4%0F%08%0F%98a%07%0F%A9%13%97%0C%8D%07tU%B2y%0F%05o%8Db%7F%C4%A9%5Cm%C1t%CC%BC%21S%C1%07%AD%D3%B1%9A%0F%0F%07%A2%D9%BD%98%DC%0F%0En%85%E0%21%87%8F%5D%E7%E0%87t%8F%02k%BC%B2%03%C6%5D%F3%BC%84%15%02%2F%E8%2C%E7t%E4CG%B0%A0%C1%83%18f%20%9C%A0%C4%A0%80%1E%2C%0C2H%81%E2%E0%11%28%0E%29.%18%98%ED%09%C5%83%0E%05%28%3AH%15%01%00%3B'>