DEV Community

Discussion on: How to sort an array of objects using the JS Sort Method

Collapse
 
frankwisniewski profile image
Frank Wisniewski

you should at least do the following:

console.log(
["Paris", "Köln", "Ähre","Buch","Ahr"].sort(Intl.Collator().compare)
)
Enter fullscreen mode Exit fullscreen mode