Replies: 1 comment 8 replies
-
Alarm! Beginner in modern web dev! |
Beta Was this translation helpful? Give feedback.
8 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Dear community,
Somehow sorting posts in Latvian results in wrong order. Please help to get the posts sorted by alphabet.
Alphabet (in total Latvian alphabet consits of 33 letters) first 8 letters:
A a | Ā ā | B b | C c | Č č | D d | E e | Ē ē ...
To sort posts according to Latvian alphabet I use localeCompare as follows:
In result posts starting with long variation letter are displayed before posts starting with short variation letter, but should be the opposite.
Result:
Should be:
Just to be sure if localeCompare actually works, tried with other languages and sorting is fine, but not for my native Latvian.
Any ideas how to force sorting posts according to Latvian alphabet?
Tested localeCompare without Eleventy and it does work. #confused
Thanks in advance,
Beta Was this translation helpful? Give feedback.
All reactions