{"action":"created","issue":{"url":"https://api.github.com/repos/w3c/web-nfc/issues/152","repository_url":"https://api.github.com/repos/w3c/web-nfc","labels_url":"https://api.github.com/repos/w3c/web-nfc/issues/152/labels{/name}","comments_url":"https://api.github.com/repos/w3c/web-nfc/issues/152/comments","events_url":"https://api.github.com/repos/w3c/web-nfc/issues/152/events","html_url":"https://github.com/w3c/web-nfc/issues/152","id":364361541,"node_id":"MDU6SXNzdWUzNjQzNjE1NDE=","number":152,"title":"Use addEventListener instead of watch","user":{"login":"kenchris","id":1101339,"node_id":"MDQ6VXNlcjExMDEzMzk=","avatar_url":"https://avatars1.githubusercontent.com/u/1101339?v=4","gravatar_id":"","url":"https://api.github.com/users/kenchris","html_url":"https://github.com/kenchris","followers_url":"https://api.github.com/users/kenchris/followers","following_url":"https://api.github.com/users/kenchris/following{/other_user}","gists_url":"https://api.github.com/users/kenchris/gists{/gist_id}","starred_url":"https://api.github.com/users/kenchris/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kenchris/subscriptions","organizations_url":"https://api.github.com/users/kenchris/orgs","repos_url":"https://api.github.com/users/kenchris/repos","events_url":"https://api.github.com/users/kenchris/events{/privacy}","received_events_url":"https://api.github.com/users/kenchris/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":6,"created_at":"2018-09-27T08:33:46Z","updated_at":"2018-09-27T11:20:41Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"I don't recall why we invented the watch, but it feels a bit like its own thing, instead of being aligned with the platform. We could go with a `startNotifications()` approach like WebBluetooth.\r\n\r\n```js\r\nnavigator.nfc.addEventListener('exchange', message => {\r\n  for (let record of message.records) {\r\n    let article =/[aeio]/.test(record.data.title) ? \"an\" : \"a\";\r\n    console.log(`${record.data.name} is ${article} ${record.data.title}`);\r\n  }\r\n},{\r\n  url: document.baseURI,\r\n  recordType: \"json\"\r\n});\r\n\r\nnavigator.nfc.startNotifications();\r\n```\r\n\r\nThis means that all of our values in the options dict needs to qualify as a separate handler (ie if you want to remove you need the same options dict and same function"},"comment":{"url":"https://api.github.com/repos/w3c/web-nfc/issues/comments/425053984","html_url":"https://github.com/w3c/web-nfc/issues/152#issuecomment-425053984","issue_url":"https://api.github.com/repos/w3c/web-nfc/issues/152","id":425053984,"node_id":"MDEyOklzc3VlQ29tbWVudDQyNTA1Mzk4NA==","user":{"login":"zolkis","id":996058,"node_id":"MDQ6VXNlcjk5NjA1OA==","avatar_url":"https://avatars3.githubusercontent.com/u/996058?v=4","gravatar_id":"","url":"https://api.github.com/users/zolkis","html_url":"https://github.com/zolkis","followers_url":"https://api.github.com/users/zolkis/followers","following_url":"https://api.github.com/users/zolkis/following{/other_user}","gists_url":"https://api.github.com/users/zolkis/gists{/gist_id}","starred_url":"https://api.github.com/users/zolkis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zolkis/subscriptions","organizations_url":"https://api.github.com/users/zolkis/orgs","repos_url":"https://api.github.com/users/zolkis/repos","events_url":"https://api.github.com/users/zolkis/events{/privacy}","received_events_url":"https://api.github.com/users/zolkis/received_events","type":"User","site_admin":false},"created_at":"2018-09-27T11:20:41Z","updated_at":"2018-09-27T11:20:41Z","author_association":"CONTRIBUTOR","body":"On the other hand we can't really expect to handle NFC interactions with Bluetooth interactions."}}
{"actor":{"display_login":"zolkis"}}