6 ms·
What is wrong with browser default styling, and why do browsers ship with something that is wrong?
by freediver 4y ago
What is wrong with browser default styling, and why do browsers ship with something that is wrong?
- djbusby 4y agoBrowsers ship with defaults that are now 20 years old - there was a cool post here about 8px body padding a while ago. It's not "wrong" it's legacy.
- postalrat 4y agoWhy is it legacy though? Shouldn't browsers be free to change it?
- soulofmischief 4y agoWeb browsers have a hard constraint of backwards compatibility. Eventually we could see some CSS directive which enables "modern" default styling, both for mobile and desktop, but it would be opt-in so that existing sites which rely on defaults do not break.
- postalrat 4y agoI bet if they did an experiment where they changed the default styles a bit very very few would complain. Most people visiting tiktok or whatever wouldn't even notice.
- soulofmischief 4y agoThink for a moment. This has nothing to do with tiktok. This has to do with your favorite personal website which hasn't been updated since 2001. And any change in default styling would be immediately noticed. Pages suddenly centered, or half the width? Increased padding? And "most people wouldn't notice" is a harmful mentality in web design which allows minorities to suffer. Most people aren't blind, either. Should we not worry about them when designing websites?
- pajamanaut 4y agoMost people visiting tiktok don't do it in their browser
- postalrat 4y agoAnd the people visiting it in a browser wouldn't notice.
- marginalia_nu 4y agoIf you change them, almost every website will look bad in your browser because most rely on some of these defaults.
- dagurp 4y agoIt would be nice if you could choose between defaults in the html tag <html style-default="2022">
- cyral 4y agoWithout max-width the content will stretch across your entire screen, which isn’t great for readability. It’s faster to read when you don’t have to look across your entire monitor and move your neck/head.
- mort96 4y agoDefault styling looks terrible and is hard to read. Humans are good at reading columns at around roughly 80 characters, while browsers default to filling the whole width of the screen with text, resulting in a column that's hundreds of characters wide. Text also gets easier to read when more spaced out; the default line height makes the text too close together. Browsers still ship the bad defaults because changing defaults would break existing websites.
- screamingninja 4y ago> Humans are good at reading columns at around roughly 80 characters What makes you say that? Anecdotally, I prefer using the full width of my screen.
- deleted 4y ago[deleted]
- danielvaughn 4y agoThere is a huge amount of research devoted to this. Of course personal preferences exist, but there are physical constraints like the degree to which your eyes can move without turning your neck and other things. It’s somewhere between 60-120 I think, with 80 right in the sweet spot.
- reaperducer 4y agoIt's actually smaller than 80 characters. There has been over a century of research into this. It's why newspapers print their stories in columns, instead of across the entire page, which would be easier.
- maweki 4y agoNewspapers have been using columns to break up long lines for well over a century. It's hard to find to the next line, if they are too long.
- roelschroeven 4y ago
- nawgz 4y agoNothing is explicitly wrong, but the spacing on lists and headers can look kind of silly. For instance, consider in Google Docs - the headers stack nicely, look clean, and lists have perfect indentation / spacing Those changes pretty much cover all this does, and it doesn't do a great job IMO. I'd let them get away with "look slightly better than defaults nearly everywhere"
- marginalia_nu 4y agoHistorical reasons. Default browser styling still carry a lot of heritage from back when screens were 640x480 and you had to squeeze as many lines as possible onto the 14" screen. Of course, if you change the default CSS now that 30 years of HTML have been written to rely on these defaults, almost every website will break.
- marcosdumay 4y agoI doubt this. Almost every website overrides all of the relevant CSS attributes, because the default is just atrocious. Changing the default won't impact them. Anyway, the browsers still can update the CSS and add a "reverse read mode" button that changes it back.
- marginalia_nu 4y agoThey override the CSS attributes that don't fit what they are doing now, but changing the defaults would introduce new attributes, which may not presently be overridden.
- BrainVirus 4y agoThe modern approach is to do a universal rest: *, *:before, *:after { all: unset; display: revert; box-sizing: border-box; }
- marginalia_nu 4y agoWould that actually work as a safeguard against this? What you're reverting and unsetting to is the very defaults we're talking about changing.
- marcosdumay 4y agoAs I understand it, it won't protect you. What will protect is actually setting the value (and most sites do that, at least for those few commonly changed ones with bad defaults).
- amelius 4y ago> What is wrong with browser default styling, and why do browsers ship with something that is wrong? The problem with browser default styling is that there should be another level: user default styling. I.e., the styling as chosen by the user.
- phil294 4y agoI think this is a valid point. For example, I have always wondered why default browser styles don't at least adjust to the OS's theme - be it Metro, Material, Qt, Gtk, whatever. It would solve a lot of issues for bare-bones websites, while still allowing full configurability for websites via override. And if we really cannot have nice things because of backwards compatibility, make OS integration optional via <meta> tag etc. Why does every website have to reinvent the wheel?