Re: [web-nfc] Use AbortController/*Signal instead of cancelWatch(optional long id);

>  push (which I think we should just rename to write 

But push was an NFC-specific term. 

> const controller = new AbortController();

I'd prefer `watch()` return the `AbortController`.

```javascript
var controller = navigator.nfc.write(message, options);
setTimeout(() => controller.abort(), 3000);
```

In some cases we cannot guarantee cancellation. What happens then? It is not specified for `AbortController` or `AbortSignal`.

-- 
GitHub Notification of comment by zolkis
Please view or discuss this issue at https://github.com/w3c/web-nfc/issues/147#issuecomment-425053443 using your GitHub account

Received on Thursday, 27 September 2018 11:18:34 UTC