diff --git a/app/soapbox/features/emoji/search.ts b/app/soapbox/features/emoji/search.ts index 2330d17f0..c4953eda9 100644 --- a/app/soapbox/features/emoji/search.ts +++ b/app/soapbox/features/emoji/search.ts @@ -11,8 +11,10 @@ const index = new Index({ context: true, }); -for (const [key, emoji] of Object.entries(data.emojis)) { - index.add('n' + key, `${emoji.keywords.join(' ')} ${emoji.name}`); +// console.log(Object.entries(data.emojis)); +const sortedEmojis = Object.entries(data.emojis).sort((a, b) => a[0].localeCompare(b[0])); +for (const [key, emoji] of sortedEmojis) { + index.add('n' + key, `${emoji.id} ${emoji.name} ${emoji.keywords.join(' ')}`); } export interface searchOptions {