Skip to content

Commit

Permalink
feat: improve sorting
Browse files Browse the repository at this point in the history
  • Loading branch information
fjc0k committed Mar 12, 2019
1 parent c71b1ef commit d46671b
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/Generator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,13 @@ export default class Generator {
},
)
paths.sort(
(a, b) => a.localeCompare(b, 'en', { sensitivity: 'base' }),
new Intl.Collator(
['en', 'co'],
{
sensitivity: 'base',
numeric: true,
},
).compare,
)
const codes = paths
.filter(path => path !== currentFile)
Expand Down

0 comments on commit d46671b

Please sign in to comment.