#5 Strip encoding information from compiled CSS

Open
h30 wants to merge 3 commits from h30/hsass-0.6.0 into fr33domlover/master

By default, when hsass outputs UTF-8 characters outside of the ASCII range, it prefixes its output with encoding information. Depending on the level of compression, this is either in the form of @charset "UTF-8" or a Byte-Order Mark. This is problematic, since Yesod does not account for the BOM when concatenating CSS. As a result, the BOM ends up in the middle of concatenated CSS (which was causing a divergence between development-mode and non-development-mode CSS on Snowdrift).

By default, when hsass outputs UTF-8 characters outside of the ASCII range, it prefixes its output with encoding information. Depending on the level of compression, this is either in the form of `@charset "UTF-8"` or a Byte-Order Mark. This is problematic, since Yesod does not account for the BOM when concatenating CSS. As a result, the BOM ends up in the middle of concatenated CSS (which was causing a divergence between development-mode and non-development-mode CSS on Snowdrift).
Henri Jones commented 6 years ago
Poster

I had to make a few changes after testing this against Snowdrift. It seems that importer now needs to return absolute paths (probably because we're using a later version of libsass).

Unfortunately this only partially fixes the production/development CSS disparity. For some reason, fonts.silius isn't being compiled correctly. I wonder if Shakespeare is struggling to parse the compressed CSS as Lucius.

I had to make a few changes after testing this against Snowdrift. It seems that `importer` now needs to return absolute paths (probably because we're using a later version of libsass). Unfortunately this only partially fixes the production/development CSS disparity. For some reason, `fonts.silius` isn't being compiled correctly. I wonder if Shakespeare is struggling to parse the compressed CSS as Lucius.
This pull request can be merged automatically.
Sign in to join this conversation.
No Label
No Milestone
No assignee
1 Participants
Loading...
Cancel
Save
There is no content yet.