The right way is the one that you choose yourself and suits your needs.
There's no default right answer to this, as the answer depends entirely on what you're sorting and how you want it sorted. Even for a given character set the "correct" alphabetical sorting is still locale dependent.
And even knowing all that, "correct" programmatic sorting might still be essentially impossible. Some digraphs may be sorted differently depending on the specific word. For example A vs Aa, where Aa means Å. But Aa won't always necessarily mean Å, so good luck figuring that out.