-
-
Notifications
You must be signed in to change notification settings - Fork 261
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update font media types #77
Comments
This would be a nice change as it is simpler and more intuitive. I am curious about browser support. |
@sholladay I responded to a now deleted tweet about that. TL;DR: browsers ignore font media types. |
Is that all browsers or only current browsers? I'd be interesting to know about current Firefox, current Firefox ESR, current Chrome, current Safari, current Edge, current IE, IE10 (probably IE9, but no lower since I think SSL is broken now on those anyway). Anything else @sholladay you would like to know about? |
I only personally care about latest of: Chrome, Firefox, Safari, Edge FYI Microsoft dropped support for IE < 11 early last year and they are no longer even remotely secure, as they stopped receiving basic security patches. IE11 has approximately 13% market share and falling quickly. It is a new day! I know the situation with fonts on mobile has traditionally been very different than desktop (e.g. for a while only SVG was supported). It wouldn't surprise me if they avoided sniffing to save battery. That is probably a bigger concern. But following the standard is a 👍 from me. |
@dougwilson The only problem was with old Blink/WebKit based browsers, which used to display a warning, but that is no longer the case. |
I wonder when Apache / NGINX will update their mappings to use these new types. I'm going to see if there are bug reports in those projects. That's where our font types are coming from today, if you were wondering :) |
@dougwilson Did you manage to look into that? Thanks! Also, in the meantime,
|
Hi @alrra I didn't check yet. I can take a look now. I would prefer this remain simply an aggregation system, as in it just passes through the other sources, so unless there is some specific reason (like types that came into existence before IANA and similar, as one example) I would rather not add things to custom.json . Our font data comes from the Apache / NGINX projects currently, so updating those projects will mean we'll pull down the new mappings. |
A quick search didn't find anything in the Apache HTTPD bug tracker, but found https://trac.nginx.org/nginx/ticket/1243 for NGINX. |
The `content-type` rule uses `mime-db` which currently doesn't¹ contain the standard² font media types. This commit fixes that by introducing code that overwrites the non-standard font media types with the standard ones. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ¹ jshttp/mime-db#77 ² https://www.iana.org/assignments/media-types/media-types.xhtml#font Close #425
@alrra you're welcome to make a pull request to get the types added, though that will just list the existing extensions twice until the upstream removes them. |
Done.
:( |
Alright, Apache changed their types now, which makes landing this fit very nicely now :O |
@dougwilson I've updated #90. |
`mime-db` now includes¹ the appropriate font media types, thus, there is no longer a need to overwrite² the font media types. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ¹ jshttp/mime-db#90 jshttp/mime-db#77 ² e35b778
`mime-db` now includes¹ the appropriate font media types, thus, there is no longer a need to overwrite² the font media types. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ¹ jshttp/mime-db#90 jshttp/mime-db#77 https://github.com/jshttp/mime-db/releases/tag/v1.31.0 ² e35b778 Close #581
The
font
top-level media type has been registered, so the new media types for font files are as follows:collection
font/collection
otf
font/otf
sfnt
font/sfnt
ttf
font/ttf
woff
font/woff
woff2
font/woff2
See also: https://www.iana.org/assignments/media-types/media-types.xhtml#font
@dougwilson I did run the
fetch-iana
script but it doesn't seem to get these updates. Let me know if you are open to updatingcustom.json
.The text was updated successfully, but these errors were encountered: