@common.js/p-queue 7.3.3 → 7.3.4
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/README.md +1 -1
- package/dist/index.d.ts +2 -2
- package/package.json +3 -2
package/README.md
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
|
|
3
3
|
The [p-queue](https://www.npmjs.com/package/p-queue) package exported as CommonJS modules.
|
|
4
4
|
|
|
5
|
-
Exported from [p-queue@7.3.
|
|
5
|
+
Exported from [p-queue@7.3.4](https://www.npmjs.com/package/p-queue/v/7.3.4) using https://github.com/etienne-martin/common.js.
|
package/dist/index.d.ts
CHANGED
|
@@ -26,19 +26,19 @@ export default class PQueue<QueueType extends Queue<RunFunction, EnqueueOptionsT
|
|
|
26
26
|
/**
|
|
27
27
|
Adds a sync or async task to the queue. Always returns a promise.
|
|
28
28
|
*/
|
|
29
|
-
add<TaskResultType>(function_: Task<TaskResultType>, options?: Partial<EnqueueOptionsType>): Promise<TaskResultType | void>;
|
|
30
29
|
add<TaskResultType>(function_: Task<TaskResultType>, options: {
|
|
31
30
|
throwOnTimeout: true;
|
|
32
31
|
} & Exclude<EnqueueOptionsType, 'throwOnTimeout'>): Promise<TaskResultType>;
|
|
32
|
+
add<TaskResultType>(function_: Task<TaskResultType>, options?: Partial<EnqueueOptionsType>): Promise<TaskResultType | void>;
|
|
33
33
|
/**
|
|
34
34
|
Same as `.add()`, but accepts an array of sync or async functions.
|
|
35
35
|
|
|
36
36
|
@returns A promise that resolves when all functions are resolved.
|
|
37
37
|
*/
|
|
38
|
-
addAll<TaskResultsType>(functions: ReadonlyArray<Task<TaskResultsType>>, options?: Partial<EnqueueOptionsType>): Promise<Array<TaskResultsType | void>>;
|
|
39
38
|
addAll<TaskResultsType>(functions: ReadonlyArray<Task<TaskResultsType>>, options?: {
|
|
40
39
|
throwOnTimeout: true;
|
|
41
40
|
} & Partial<Exclude<EnqueueOptionsType, 'throwOnTimeout'>>): Promise<TaskResultsType[]>;
|
|
41
|
+
addAll<TaskResultsType>(functions: ReadonlyArray<Task<TaskResultsType>>, options?: Partial<EnqueueOptionsType>): Promise<Array<TaskResultsType | void>>;
|
|
42
42
|
/**
|
|
43
43
|
Start (or resume) executing enqueued tasks within concurrency limit. No need to call this if queue is not paused (via `options.autoStart = false` or by `.pause()` method.)
|
|
44
44
|
*/
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@common.js/p-queue",
|
|
3
|
-
"version": "7.3.
|
|
3
|
+
"version": "7.3.4",
|
|
4
4
|
"description": "p-queue package exported as CommonJS modules",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": "etienne-martin/common.js",
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
},
|
|
12
12
|
"scripts": {
|
|
13
13
|
"build": "del-cli dist && tsc",
|
|
14
|
-
"test": "xo && ava",
|
|
14
|
+
"test": "xo && ava && del-cli dist && tsc && tsd",
|
|
15
15
|
"bench": "node --loader=ts-node/esm bench.ts"
|
|
16
16
|
},
|
|
17
17
|
"files": [
|
|
@@ -35,6 +35,7 @@
|
|
|
35
35
|
"random-int": "^3.0.0",
|
|
36
36
|
"time-span": "^5.0.0",
|
|
37
37
|
"ts-node": "^10.9.1",
|
|
38
|
+
"tsd": "^0.25.0",
|
|
38
39
|
"typescript": "^4.8.4",
|
|
39
40
|
"xo": "^0.44.0"
|
|
40
41
|
},
|