feat: rebuild search index
This commit is contained in:
1 parent
0b5efbb5e1
commit
c7827a2d77
6 files changed
+84
No files matched your search
@@ -302,6 +302,13 @@ const App: React.FC = () => {
|
||||
}) || (() => {})
|
||||
);
|
||||
|
||||
unsubscribers.push(
|
||||
window.electronAPI?.on('menu:reindexText', () => {
|
||||
// Fire and forget - runs as a background task
|
||||
window.electronAPI?.posts.reindexText();
|
||||
}) || (() => {})
|
||||
);
|
||||
|
||||
return () => {
|
||||
unsubscribers.forEach(unsub => unsub());
|
||||
};
|
||||
|
||||
Vendored
+1
@@ -149,6 +149,7 @@ export interface ElectronAPI {
|
||||
discard: (id: string) => Promise<PostData | null>;
|
||||
hasPublishedVersion: (id: string) => Promise<boolean>;
|
||||
rebuildFromFiles: () => Promise<void>;
|
||||
reindexText: () => Promise<void>;
|
||||
search: (query: string) => Promise<SearchResult[]>;
|
||||
filter: (filter: PostFilter) => Promise<PostData[]>;
|
||||
getTags: () => Promise<string[]>;
|
||||
|
||||
Reference in new issue
Block a user