Skip to content
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

fix(all,cli,render,tailwind): use rehype, remove cheerio and terser #75

Merged
merged 4 commits into from Nov 13, 2023

Conversation

shellscape
Copy link
Owner

Component / Package Name:

This PR contains:

  • bugfix
  • feature
  • refactor
  • documentation
  • other

Are tests included?

  • yes (bugfixes and features will not be merged without tests)
  • no

Breaking Changes?

  • yes (breaking changes will not be merged unless absolutely necessary)
  • no

If yes, please include "BREAKING CHANGES:" in the first commit message body, followed by a description of what is breaking.

List any relevant issue numbers:

Description

While technically the differences in output could constitute a breaking change, nothing in the API layer of the project has changed.

Retesting output from jsx-email is not a recommended practice. Howeer, If you were re-testing output from jsx-email, you'll want to update those tests.

This PR swaps out cheerio and html-minifier-terser for rehype and comparable plugins. cheerio and html-minifier-terser are very good and very fast, and that's why we initially went with them. However, they give Vite a lot of trouble while running the dev server, and so the decision was made to move to something else. Rehype does a fine job, and while the minification output is ever so slightly larger, it's much faster at both manipulating the HTML (which cheerio was doing for us) and minifying.

@shellscape shellscape force-pushed the fix/render/use-rehype branch 3 times, most recently from 22e1e02 to a45882c Compare November 13, 2023 03:03
@shellscape shellscape changed the title fix(cli,render,tailwind): use rehype, remove cheerio and terser fix(all,cli,render,tailwind): use rehype, remove cheerio and terser Nov 13, 2023
@shellscape shellscape merged commit 9f0918c into main Nov 13, 2023
2 checks passed
@shellscape shellscape deleted the fix/render/use-rehype branch November 13, 2023 03:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant