This is case sensitive sorting where lowercase letters come after uppercase letters. Thus, for sorting and searching, it makes sense to store a "normalized field", where all lines are headers, and some special characters are deleted or replaced, for example.
[ { name : "iTaxi", searchName: "ITAXI" }, { name : "HTC", searchName: "HTC" }, { name : "Γmlaut", searchName: "UMLAUT" }, .... ]
In this example, the searchName field should be indexed, not the name field.
Normalizing strings, especially replacing umlauts and special characters, is a bit complicated. For example, German ΓΌ should become ue , and Γ should become ss or sz , but that goes far beyond the scope of your original question.
source share