Menu

I switched the stylesheet off on all 106 of our pages, and the only text that changed was the nav
📰

I switched the stylesheet off on all 106 of our pages, and the only text that changed was the nav

DEV Community: html·Daniel Pertu·6 days ago
#KwgyCB5A
#devto2#devto#dev#every#stylesheet
Long article (1324 words) — no AI summary yet.
Reading 0:00
15s threshold

Nakodo has no images. 106 public pages, not one <img> tag, every drawing inline SVG, every layout rule from Tailwind. That makes it a good subject for a question I had not tested on any site I have built: if the stylesheet never arrives, is the thing still readable?

You can run the experiment on any page in one line:

for ( const sheet of document . styleSheets ) sheet . disabled = true ;

Enter fullscreen mode

Exit fullscreen mode

That is cheaper than it sounds as a test, because it stands in for several real situations at once. A stylesheet that 404s after a bad deploy. A corporate proxy that strips assets. Reader mode. A text browser. A model reading your HTML. All of them are, roughly, your markup without your CSS.

The run

For each of the 106 URLs in our sitemap : load, measure, disable every sheet, measure again.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.