Here is the queue removal broken out, per this pull
Add a method to empty the queue. This does not touch any requests cur…
…rently in flight
Do you think this should call abort on all the requests in the queue?
Also, could you make sure to add some documentation in the README.md on this? :)
The ability to clear the queue would be very nice.
In my opinion it should clear the entire queue (all the requests).
Update the docs to describe the clearing functionality
Sorry for the delay on this, it fell off my radar. I could actually see providing an option to clear() that would let the caller decide whether the individual requests should be aborted as well. The particular use case I had for adding it was because i aggressively queued things (on change of a form), and at a certain point, wanted to drop all the pending requests without worrying about any callbacks being triggered.
This also won't cancel the currently running queue item, which might cause some problems whenever that request finishes, it will end up starting the next queued request and you'll have a concurrency of 2. I think we need .abort() to be able to do this correctly. Though having .clear() to just clear the queue is useful, I'd really prefer to see both together.
Closing for #13