We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 95d9445 commit 7a74f0bCopy full SHA for 7a74f0b
js/finder.ts
@@ -20,11 +20,11 @@ export default class Finder {
20
private fzf: Fzf<string[]>;
21
22
private docs: Record<string, Omit<StoreDoc, 'id' | 'title'>> = {};
23
- private titles: string[] = [];
+ private titlesByKey: Record<string, string> = {};
24
25
constructor(storeDocs: Record<string, StoreDoc>, limit: number) {
26
for (const [key, { id, title, ...rest }] of Object.entries(storeDocs)) {
27
- this.titles.push(title);
+ this.titlesByKey[key] = title;
28
this.docs[key] = rest;
29
}
30
0 commit comments