Support new plugin: prettier-plugin-jsx-attr-sort#383
Closed
mattiamalonni wants to merge 3 commits intotailwindlabs:mainfrom
Closed
Support new plugin: prettier-plugin-jsx-attr-sort#383mattiamalonni wants to merge 3 commits intotailwindlabs:mainfrom
mattiamalonni wants to merge 3 commits intotailwindlabs:mainfrom
Conversation
* tailwind-main: Upgrade dev dependencies (tailwindlabs#388) # Conflicts: # package-lock.json # package.json
* tailwind-main: Add support for callable template literals when using custom JSX parser (tailwindlabs#367) Handle quotes in `@plugin`, `@config`, and `@source` (tailwindlabs#387) Drop support for `prettier-plugin-import-sort` (tailwindlabs#385) Remove `declare` to clean up global scope (tailwindlabs#354)
Author
|
Just wondering if there are any updates or blockers on this PR? |
Contributor
|
So — we'd normally want to wait on merging support for new plugins until it becomes more widely used and/or asked for. I'll start a discussion about this internally though and get back to you 👍 |
Contributor
|
We discussed this a bit internally and have decided (for now) to close this. If the plugin becomes more popular in the future we'll absolutely reconsider. Aside: I do hate that it can't "just work" without us having to explicitly add support for it but with Prettier's current design that's just not possible — which is why we have to load plugins this way in the first place. |
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
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.
I’ve built a Prettier plugin to sort JSX/TSX attributes alphabetically while preserving key/ref order and respecting spread attribute positions.
It uses a preprocess function and is compatible with prettier-plugin-tailwindcss through proper merging of preprocess.
Would you be open to supporting it via your plugin discovery mechanism?
https://github.com/mattiamalonni/prettier-plugin-jsx-attr-sort