Add a default charset to content-type on webrick. #4231

Merged
merged 1 commit into from Dec 7, 2015

Conversation

Projects
None yet
3 participants
@jekyllbot
Contributor

jekyllbot commented Dec 7, 2015

PR automatically created for @envygeeks.

Add a default charset to content-type on webrick.

Add a default charset to content-type on webrick, using Jekyll's
default encoding (or user set encoding) and cleanup servlet removing
unecessary logic that really served no purpose at the end of the
day, we don't need to strictly match Nginx, only be "like it."

This also cleans up the way we set headers and merges that logic
into a cleaner to understand interface that is slightly speedier.```
Add a default charset to content-type on webrick.
Add a default charset to content-type on webrick, using Jekyll's
default encoding (or user set encoding) and cleanup servlet removing
unecessary logic that really served no purpose at the end of the
day, we don't need to strictly match Nginx, only be "like it."

This also cleans up the way we set headers and merges that logic
into a cleaner to understand interface that is slightly speedier.

@envygeeks envygeeks changed the title from Add a default charset to content-type on webrick. Add a default charset to content-type on webrick, using Jekyll's default encoding (or user set encoding) and cleanup servlet removing unecessary logic that really served no purpose at the end of the day, we don't need to strictly match Nginx, only be "like it." This also cleans up the way we set headers and merges that logic into a cleaner to understand interface that is slightly speedier. to Add a default charset to content-type on webrick. Dec 7, 2015

@envygeeks

This comment has been minimized.

Show comment
Hide comment
@envygeeks

envygeeks Dec 7, 2015

Contributor

/cc @jekyll/core

Recently while building a quick prototype I noticed a few custom fonts we offer to people were not being displayed right, ultimately it turned out to be that I forgot to set the charset in the HTML file, but it worked on the Docker image with Nginx on port 80, so I went on a crusade to figure out what the difference was and it took one minute before I realized that webrick doesn't send a charset with the content-type like Nginx, this should ease a lot of developer pains by shipping one so people aren't taken by surprise when their stuff works on Github and Nginx and Apache but not on our development servers.

Contributor

envygeeks commented Dec 7, 2015

/cc @jekyll/core

Recently while building a quick prototype I noticed a few custom fonts we offer to people were not being displayed right, ultimately it turned out to be that I forgot to set the charset in the HTML file, but it worked on the Docker image with Nginx on port 80, so I went on a crusade to figure out what the difference was and it took one minute before I realized that webrick doesn't send a charset with the content-type like Nginx, this should ease a lot of developer pains by shipping one so people aren't taken by surprise when their stuff works on Github and Nginx and Apache but not on our development servers.

@envygeeks envygeeks added this to the 3.1 milestone Dec 7, 2015

@envygeeks envygeeks self-assigned this Dec 7, 2015

parkr added a commit that referenced this pull request Dec 7, 2015

Merge pull request #4231 from jekyll/pull/add-default-charset-to-webr…
…ick-cleanup-servlet

Merge pull request 4231

@parkr parkr merged commit 7f9fd11 into master Dec 7, 2015

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@parkr parkr deleted the pull/add-default-charset-to-webrick-cleanup-servlet branch Dec 7, 2015

parkr added a commit that referenced this pull request Dec 7, 2015

@parkr

This comment has been minimized.

Show comment
Hide comment
@parkr

parkr Dec 7, 2015

Member

Thanks!

Member

parkr commented Dec 7, 2015

Thanks!

@jekyll jekyll locked and limited conversation to collaborators Feb 27, 2017

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.