@serwist/background-sync 8.4.4 → 9.0.0-preview.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/BackgroundSyncPlugin.d.ts +1 -0
- package/dist/BackgroundSyncPlugin.d.ts.map +1 -0
- package/dist/Queue.d.ts +2 -1
- package/dist/Queue.d.ts.map +1 -0
- package/dist/QueueDb.d.ts +1 -0
- package/dist/QueueDb.d.ts.map +1 -0
- package/dist/QueueStore.d.ts +1 -0
- package/dist/QueueStore.d.ts.map +1 -0
- package/dist/StorableRequest.d.ts +1 -0
- package/dist/StorableRequest.d.ts.map +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -0
- package/package.json +18 -17
- package/src/BackgroundSyncPlugin.ts +40 -0
- package/src/Queue.ts +444 -0
- package/src/QueueDb.ts +176 -0
- package/src/QueueStore.ts +161 -0
- package/src/StorableRequest.ts +144 -0
- package/src/index.ts +37 -0
- package/dist/index.cjs +0 -710
- package/dist/index.d.cts +0 -23
package/dist/index.d.cts
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { BackgroundSyncPlugin } from "./BackgroundSyncPlugin.js";
|
|
2
|
-
import type { QueueEntry, QueueOptions } from "./Queue.js";
|
|
3
|
-
import { Queue } from "./Queue.js";
|
|
4
|
-
import { QueueStore } from "./QueueStore.js";
|
|
5
|
-
import { StorableRequest } from "./StorableRequest.js";
|
|
6
|
-
interface SyncManager {
|
|
7
|
-
getTags(): Promise<string[]>;
|
|
8
|
-
register(tag: string): Promise<void>;
|
|
9
|
-
}
|
|
10
|
-
declare global {
|
|
11
|
-
interface ServiceWorkerRegistration {
|
|
12
|
-
readonly sync: SyncManager;
|
|
13
|
-
}
|
|
14
|
-
interface SyncEvent extends ExtendableEvent {
|
|
15
|
-
readonly lastChance: boolean;
|
|
16
|
-
readonly tag: string;
|
|
17
|
-
}
|
|
18
|
-
interface ServiceWorkerGlobalScopeEventMap {
|
|
19
|
-
sync: SyncEvent;
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
export { BackgroundSyncPlugin, Queue, QueueStore, StorableRequest };
|
|
23
|
-
export type { QueueOptions, QueueEntry };
|