6 ms·
Maybe I'm being naïve, but why don't browsers ship with more popular fonts bundled to avoid problems like these? I have no issue with any of my browsers taking
by lukepothier 6y ago
Maybe I'm being naïve, but why don't browsers ship with more popular fonts bundled to avoid problems like these? I have no issue with any of my browsers taking up fractionally more space for an extensive cache of the most popular web fonts when the payoff is better performance on so many sites.
Of course, servers should still be capable of serving the fonts that the client requires to render the content correctly, but the browser should be equipped to make that happen as quickly as possible.
- jakub_g 6y agoI'm not an expert but: - 1. Copyright (though many fonts are free, true) - 2. Everyone uses a different font (just like everyone uses a slightly different version jquery) so cache hit would be pretty small IMO. Do you really want a browser to be gigabytes large? Especially on mobile it's not viable Maybe if browsers standardized on shipping, say, 20 carefully chosen fonts (not necessarily the most popular ones, just a good variety of different types of fonts), the smaller websites would follow and use them; but I think any major brand likes to distinguish themselves and have a custom unique font.
- dubcanada 6y agoI mean I’ve said it before but shipping like 20 (montserrat, raleway, open sans, etc) would cover most websites who use Google Fonts.
- jakub_g 6y agoYou might be right, but the next question is fashion. Will the same fonts be used still in 5 years, or (more likely) the new hotness will arrive? Should the browsers update the list each year? Then some fonts that were available will suddenly be not? Not so great. Web standards and browser features are generally built for the long term and backward compatibility. I mean, it's not impossible to find a solution, but it's definitely not "let's download some fonts and bundle with the browser, done" kind of problem.
- netheril96 6y agoAt least it is not a problem for Google, since it controls both the most popular browse and most popular web font distribution channels.
- thrower123 6y agoWhen you control 70% of the desktop market share, and you are releasing an evergreen browser that updates weekly, if not more frequently, any argument about not being able to stay on top of changes in the environment become rather silly.
- ClumsyPilot 6y agoWe keep root ssl certificates up to date, surely we can handle a few fonts.
- flomo 6y agoMicrosoft's old "core fonts for the web" are still widely in use. (including here on HN.)
- jfk13 6y agoDo we really want to invite a couple of browser vendors to set the course of typographic design for the next few decades?
- zinekeller 6y ago> Maybe if browsers standardized on shipping, say, 20 carefully chosen fonts (not necessarily the most popular ones, just a good variety of different types of fonts), the smaller websites would follow and use them; but I think any major brand likes to distinguish themselves and have a custom unique font. It may be not really carefully chosen, but didn't Microsoft have done this already? (Core fonts for the Web, https://web.archive.org/web/20020124085641/http://www.microsoft.com/typography/fontpack/default.htm https://web.archive.org/web/20020124085641/http://www.micros...). The reason they have discontinued this programme is that it actually costs them some money (as the fonts are not owned by Microsoft.) Also, how would you cater to non-LGC (Latin, Greek, Cyrillic) users?
- jakub_g 6y agoYep Asian fonts in particular are _huge_. It's a complex topic.
- deleted 6y ago[deleted]
- marcthe12 6y agoI believe already there but maybe a set of categories of fonts like UI, sans, monospace, handwriting could be alias usual for all websites and apps
- ClumsyPilot 6y ago> "Do you really want a browser to be gigabytes large? Especially on mobile it's not viable" Absolutely, i would rather give the browser 50 GB even on my phone over paying my mobile operator for downloading the same data over and over again. And it wouldn't take anywhere near that much, I am sure 80% of most used fonts are only a couple dozen, that wouldn't tale gigabytes
- cj 6y agoIt also doesn't have to be a binary proposition. For example, Google Maps by default doesn't load maps of the entire world when you install it. However, it does let you opt-in to pre-downloading specific areas that you frequently travel. Browsers could do the same by simply adding an opt-in to download / cache common assets like fonts, jquery, etc.
- rovr138 6y agoFrom a privacy point of view, Not embedding all of them would allow tracking. Caching all web fonts would allow tracking. The solution is embedding all the popular ones so everyone has them and it can't be used as a signal.
- sergeykish 6y agoIt would be interesting to gather a list. uBlock Origin can disable Web Fonts https://github.com/gorhill/uBlock/wiki/Per-site-switches#no-remote-fonts https://github.com/gorhill/uBlock/wiki/Per-site-switches#no-... so it should be possible to log. And given a list it is not hard to download.
- SquareWheel 6y agoI've always thought the same. I see the same web fonts being used time and time again. It just makes sense for browsers to have an intelligent "permanent cache" - not based on your specific history but a common set of frequently sourced fonts, libraries, etc. This would be especially helpful now that shared caches are going away. One other option is to actually install the font into your OS. Any correctly-coded website will try a local source first, which should help a lot for poor connections.
- vbezhenar 6y ago> Any correctly-coded website will try a local source first, which should help a lot for poor connections. Then Google Fonts is not correctly coded, as it'll use remote font only. And myriads of websites reusing Google Fonts snippets. To try local source first, you have to explicitly ask for it in @font-face/src which Google Fonts does not do. So installing font into your OS won't help you with any website using Google Fonts service.
- zinekeller 6y ago> Then Google Fonts is not correctly coded, as it'll use remote font only. For a good technical reason: the version installed on the computer may not really match whatever the version on Google Fonts serves (fonts have notoriously no semantic versioning aside from some programmer-oriented fonts, examples of these outside are Segoe UI (changed between Windows 7 and 8) and Liberation fonts (some versions notoriously lack some glyph symbols) and on Google Fonts platform the Exo and Exo 2 problem (which was resolved by renaming the second version to Exo 2)). Of course, there are also some benefits to Google (you know what are those benefits are).
- SquareWheel 6y agoI wasn't aware Google Fonts' CSS didn't include local. That's disappointing. Thanks for letting me know!
- jfk13 6y agoI've definitely seen use of src:local(...) in the CSS served by Google Fonts in the past, but they may have changed things, or perhaps it depends on details of the request, the detected browser, etc. YMMV.
- afrcnc 6y agoanswer: licensing. nightmare. fuel.
- acdha 6y agoCopyright and size: fonts are larger than you might think because they need full Unicode support and good fonts have tuned variants for different weights, styles, and sizes, along with alternate symbols and ligatures, etc. which all add up. Self-hosting is the way to go since it gives you full artistic control and you can use things like the Unicode-range CSS property to tell clients how to combine smaller fonts so you can support many languages without forcing a French browser to download a ton of Chinese glyphs which aren’t used on the page. Another nice option we have now is using font-display to allow using a similar system font until downloads are completed, which can work really well for slow connections: https://calendar.perfplanet.com/2020/a-font-display-setting-for-slow-connections/ https://calendar.perfplanet.com/2020/a-font-display-setting-...
- lukepothier 6y ago> fonts are larger than you might think because they need full Unicode support Correct me if I'm misunderstanding, but don't the vast majority of fonts _not_ include full Unicode support, or even close to it? I know of GNU Unifont, but not many people are using that on the web... I take your point on selectively downloading the relevant glyphs for the user's locale, but this could be done by the browser too - it is aware of the locale.
- acdha 6y agofull coverage, yes, that's relatively uncommon but the most popular fonts will have a wide variety of languages and that adds up even if you don't support Chinese but do want coverage of the range of fonts designers want to use.
- dddddaviddddd 6y agoe.g. Chrome could ship with the Google fonts. Would improve the experience of something like 50% of web users.
- preommr 6y agoBecause web tech (and Google in particular) is a mess of weird politics. There are some things that are really well executed, and other things where the ball gets dropped completely. Chrome will come along and do something like hide parts of the url, or allow scroll-jacking, but then say that fonts should probably be a system level implementation. It would be trivial for the chrome team to establish something like a series of web-safe fonts like Roboto, Inter, Merriweather, etc. Stuff that gets used incredibly often. Even things like licensing aren't really an issue when most of these fonts are under their open license not to mention that Google has the money to be able to license it if they wanted to.
- austinpena 6y agoDoesn’t google benefit from getting data on where fonts are served?
- rambojazz 6y agoWhy can't users install the fonts directly on their OSes instead? If it's on the OS, browsers can pick them up and I can install only the fonts I want.
- young_unixer 6y agoI'm a "proficient" computer user and don't really know how to install fonts on my OS. I could learn how to do it in 30 minutes, but I don't feel like spending 30 minutes learning that. I'd guess that 99% of users don't know how to install fonts or simply don't care about it enough to their spend time installing fonts.