- From: Anne van Kesteren via GitHub <sysbot+gh@w3.org>
- Date: Tue, 11 Aug 2015 13:28:06 +0000
- To: public-web-nfc@w3.org
You could either do that or keep them distinct, with a `type` property getter and a `mimeType` property getter. If the former returns "opaque", the latter will not be the empty string. Kind of depends on how you expect developers will want to branch their code. Seemed reasonable to me that you'd just have: ```js if(data.type === "url") { ... } else if(data.type === "text") { ... } else if(data.type === "image/png") { ... } else { reportError() }``` -- GitHub Notif of comment by annevk See https://github.com/w3c/web-nfc/issues/26#issuecomment-129872882
Received on Tuesday, 11 August 2015 13:28:07 UTC