MCPcopy
hub / github.com/sindresorhus/p-queue / sizeBy

Method sizeBy

source/index.ts:794–797  ·  view source on GitHub ↗

Size of the queue, filtered by the given options. For example, this can be used to find the number of items remaining in the queue with a specific priority level.

(options: Readonly<Partial<EnqueueOptionsType>>)

Source from the content-addressed store, hash-verified

792 For example, this can be used to find the number of items remaining in the queue with a specific priority level.
793 */
794 sizeBy(options: Readonly<Partial<EnqueueOptionsType>>): number {
795 // eslint-disable-next-line unicorn/no-array-callback-reference
796 return this.#queue.filter(options).length;
797 }
798
799 /**
800 Number of running items (no longer in the queue).

Callers 1

basic.tsFile · 0.80

Calls 1

filterMethod · 0.80

Tested by

no test coverage detected