-
Notifications
You must be signed in to change notification settings - Fork 26
Update woff mime-type and define new one for woff2. #54
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
Conversation
# Add again with newer mime-type | ||
sed -i "s/}/\n font\/woff woff;\n&/" /etc/nginx/mime.types && \ | ||
# Also add mime-type for WOFF2 | ||
sed -i "s/}/\n font\/woff2 woff2;\n&/g" /etc/nginx/mime.types |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I figured more lines that did specific things was more legible and simpler to understand, a single-line version is probably possible here if we think that's a better approach.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@eerikson could you add the link to the nginx ticket to track as a comment before your implementation?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah of course, thanks for reminding me! Added.
ff7bbd2
to
f92d6d9
Compare
Dockerfile
Outdated
# Remove older WOFF mime-type | ||
sed -i "/application\/font-woff/d" /etc/nginx/mime.types && \ | ||
# Add again with newer mime-type | ||
sed -i "s/}/\n font\/woff woff;\n&/" /etc/nginx/mime.types && \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nitpick but can we remove the second newline (\n
) here, the one after the semicolon. The result will have both fonts together at the end of the file as opposed to 1 line apart.
i.e
font/woff woff;
font/woff2 woff2;
}
instead of
font/woff woff;
font/woff2 woff2;
}
@eerikson One comment but very nice |
fixes adobe-community/issues#19309
f92d6d9
to
f4364d7
Compare
fixes adobe-community/issues#19309