Re: [whatwg/fetch] Aborting a fetch: The Next Generation (#447)

@optimalisatie Nice work! Can it be fashioned into a spec polyfill? I prefer the spec API. E.g.:
```js
async function foo(signal) {
  try {
    let response = await fetch('https://foo.com/some.resource.js', {signal});
    console.log('response ' + await response.text().length);
  } catch(err) {
    console.log(err);
  }
}

let control = new FetchController();
foo(control.signal);
setTimeout(() => control.abort(), 10); // abort foo after 10ms
```

-- 
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/fetch/issues/447#issuecomment-316253023

Received on Wednesday, 19 July 2017 02:18:51 UTC