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

Add importOrderCaseInsensitive option again #151

Open
angrybacon opened this issue Feb 23, 2024 · 4 comments
Open

Add importOrderCaseInsensitive option again #151

angrybacon opened this issue Feb 23, 2024 · 4 comments
Labels
enhancement New feature or request

Comments

@angrybacon
Copy link

There's value in sorting uppercase first: constants, constructors and functions become sorted in that order.

Support for case sensitive sorting was dropped here #63

@IanVS IanVS added the enhancement New feature or request label Feb 26, 2024
@IanVS IanVS removed their assignment Feb 26, 2024
@IanVS
Copy link
Owner

IanVS commented Jun 25, 2024

Leaving this open so that others can vote with 👍, and we'll consider it depending on the demand.

@jar145
Copy link

jar145 commented Jun 29, 2024

I'm curious why this was removed in the first place? I'm happy to make a PR if time is the issue.

@IanVS
Copy link
Owner

IanVS commented Jun 30, 2024

It was removed because there were a ton of options previously, which goes against the philosophy of prettier. There more options there are, the more you have to think about decisions when setting it up, and the more complex the codebase becomes.

@acnebs
Copy link

acnebs commented Sep 9, 2024

I not only want case-sensitivity, but also think that this should be the default. Here is a prime example of why I think this is the case:

import {
  faAngleLeft,
  faAngleRight,
  faArrowDown,
  faArrowLeft,
  faArrowRight,
  faArrowsV,
  faArrowUp,
  faSearch,
  faSmile,
  faTvRetro,
} from '@fortawesome/pro-regular-svg-icons';

@ianvs/prettier-plugin-sort-imports sorts the faArrowsV before the faArrowsUp, which I think is very strange when you look at it. It makes much more sense for the "arrow" icon to be sorted with the other "arrow" (singular) icons, and then for the "arrows" icon to come after (or before), the point is that case-insensitivity to me seems like a very strange default.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants