PQueue decorator
npm install p-queue-decoratorDecorator, that wraps your class methods with dedicated p-queue instances
``ts
import { PQueue } from 'p-queue-decorator'
class Test {
@PQueue(/ optional https://github.com/sindresorhus/p-queue#options /)
async method(a: number, b: number) {
return a + b // method call will be through PQueue instance
}
@PQueue()
async method2(a: number, b: number) {
return a + b // for this method another PQueue instance will be used
}
}
``