dogweather / naturally

Natural sort algorithm
MIT License
87 stars 20 forks source link

Case Insensitive Sort #3

Closed schlick closed 10 years ago

schlick commented 11 years ago

Here's a scenario that would be nice if naturally could handle:

['a', 'b', 'c', 'A', 'B', 'C'] => ['A', 'a', 'B', 'b', 'C', 'c']

Currently naturally returns:

Naturally.sort(['a', 'b', 'c', 'A', 'B', 'C']) => ['A', 'B', 'C', 'a', 'b', 'c']
dogweather commented 11 years ago

I can imagine that this would be best handled by an option to specify particular sort orders like these.

dogweather commented 10 years ago

I'm going to close this as a "won't do" for the time being. If demand increases, or a pull request is submitted, then I'll revisit it.