- From: James M Snell <notifications@github.com>
- Date: Tue, 09 Mar 2021 10:57:14 -0800
- To: whatwg/dom <dom@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Tuesday, 9 March 2021 18:57:26 UTC
The most recent use case I've seen this for is the easiest/clearest... It's in the context of an HTTP request in Node.js: 1. An `AbortController`/`AbortSignal` is associated with an HTTP request. 2. The `AbortController`/`AbortSignal` is lazily created (that is, it is only created the first time it is explicitly asked for) 3. The HTTP request may already be aborted by the time the `AbortController`/`AbortSignal` is requested, in which case we want to just return an already aborted signal as opposed to `undefined` or throwing. Very simple, and along the same lines as (for instance) `Promise.reject()`. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/whatwg/dom/issues/959#issuecomment-794307026
Received on Tuesday, 9 March 2021 18:57:26 UTC