refactor: upgrade nip17

This commit is contained in:
2024-04-29 17:41:11 +01:00
parent c775236438
commit 87144d9395
15 changed files with 97 additions and 33 deletions

View File

@ -40,6 +40,7 @@ export type CachedTable<T> = {
buffer(keys: Array<string>): Promise<Array<string>>;
key(of: T): string;
snapshot(): Array<T>;
search(q: string): Promise<Array<T>>;
} & EventEmitter<CacheEvents>;
/**
@ -225,4 +226,5 @@ export abstract class FeedCache<TCached> extends EventEmitter<CacheEvents> imple
abstract key(of: TCached): string;
abstract takeSnapshot(): Array<TCached>;
abstract search(q: string): Promise<Array<TCached>>;
}