- From: Jake Archibald <notifications@github.com>
- Date: Thu, 19 Nov 2020 01:28:57 -0800
- To: whatwg/dom <dom@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Thursday, 19 November 2020 09:29:09 UTC
Bit of a half baked idea, but should we make it easier to throw abort errors from signals? Something like: ```js AbortSignal.prototype.assertNotAborted = function(message = 'Aborted') { if (this.aborted) throw new DOMException(message, 'AbortError'); } ``` I know it's a one-liner, but it might encourage using the right kind of error? -- 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/927
Received on Thursday, 19 November 2020 09:29:09 UTC