-
-
Notifications
You must be signed in to change notification settings - Fork 38
Adapt CLI with changes in TailwindCSS V3 #281
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
Merged
Merged
Changes from all commits
Commits
Show all changes
28 commits
Select commit
Hold shift + click to select a range
a9656d6
feat: enable jit features all the time
muhammadsammy e4e28d5
chore: pump up tailwindcss version to v3.0.0-alpha.1
muhammadsammy f978a3a
feat: add variants to the cli as it's removed from the new config
muhammadsammy 8856c27
chore: move constants to a constants folder
muhammadsammy 71b8d22
chore: add colors to constants
muhammadsammy 462f8a7
feat: update config closure evaluator to evaluate new tailwind3 configs
muhammadsammy cc3e294
feat!: rename overflow-clip & overflow-ellipsis to text-clip & text-e…
muhammadsammy 011ba1a
refactor: simplify pseudoclassess generation method
muhammadsammy 3379bff
fix: use correct condition for adding a dark mode variant
muhammadsammy b86ba8e
chore: remove wrong doc comment for parser getVariants method
muhammadsammy 233390b
refactor: add base pseudoclassess to thier array outside `for of` loop
muhammadsammy a8173c7
feat: generate utility function for all category types ( #293)
muhammadsammy 13ac441
fix: pass the parser into the fileContentGenerator instead of prefix
muhammadsammy 9969289
fix: disable duplicate breakpoint pseudoclass variants generation
muhammadsammy 37e508c
chore: rename classnames template funtion in FileContentGenerator
muhammadsammy e9f9488
feat(cli): generate per-category classnames
muhammadsammy 8172a88
feat: add pseudoclassnames to their category function
muhammadsammy 584ef7a
perf: use TS template literal types to generate pseudoclassess types
muhammadsammy a64f0d9
chore: make utity functions camel cased
muhammadsammy a8e2061
feat: generate utility functions for subcategories instead of categories
muhammadsammy 8b5f3f2
chore: change default export object shape
muhammadsammy b82d4ad
perf: disable JIT opacity prefix feature
muhammadsammy 756053f
fix: generate correct module exports
muhammadsammy bafc548
refactor: use a generic type for utility functions
muhammadsammy 9c63930
chore: remove redundant code in `FileContentGenerator` class
muhammadsammy 417adb1
fix: correctly generate border colors with no side `border-red-100`
muhammadsammy 30e7a20
refactor: make `_generatedClassnames` field readonly in FileContentG…
muhammadsammy ca1e8d1
feat: add classnames with important modifiers to utility functions
muhammadsammy File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
This file contains hidden or 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
Oops, something went wrong.
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.
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.
Not sure if it would improve or worsen perf, but some of the things this lib is doing can be accomplished using template string types:
This could potentially be used to implement a lot of things in the lib with less code.
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.
Thank you! I think this will make file size much smaller
Would you like to make a PR with this change to be merged into master for v2 releases?
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'll take a shot at it 👍
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'm already using Tailwind 3 myself, so I thought maybe I should do the changes on top of this PR. Do you think that would be a good idea?
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.
Hey, I've tested this approach on pseudoclasses, and it was extremely slow
But it was OK when applying this approach to important modifiers only
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.
And yes, it makes more sense to do the changes on top of this PR. Thank you!