-
Notifications
You must be signed in to change notification settings - Fork 21
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
Migrating to using LightningCSS #238
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
LightningCSS has matured a fair bit and can potentially replace many of the items in the postcss toolset. I just need to thoroughly test it to make sure.
I wanted to get this mixin plugin to work with LightningCSS as well but I can't quite figure it out yet.
Added a visitor to the LightningCSS build to ensure the Font URLs in `dist/css/black-highlighter.css` were correct. Also made some changes to the Makefiles. It checks if the images in `dist` already exist and, if they do, only runs the image optimization if the filesizes are different. I also added a `touch` to the CSS build since it seemed to be always running those `bun postcss` command but not updating the update time for the output file, for some reason. There's probably a better way to remedy this but it works for now.
Hmm, genuinely not sure why the build is failing. It says |
Seeing if `SVGO_PATH := $(shell which svgo)` can fix the svgo not found issue.
Hopefully this fixes the issue
Is not necessary with bun
emmiegit
reviewed
Jan 8, 2024
emmiegit
approved these changes
Jan 9, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
LightningCSS is just faster and replaces a number of PostCSS plugins, making the number of required package installations lower. The resulting minified CSS file is also, theoretically, slightly faster to load compared to the old one. Haven't exactly tested this myself but it should be.
I also made some small changes to a few make files just to make the build process a little more efficient since some commands were being run even when they didn't need to. I'm not exactly the makefile expert so feel free to suggest any better methods if they exist!