Re: [web-nfc] Change `toRecords()` to `records` (#362)

Right, empty array is less type checking - but then how to differentiate an error condition from empty payload. OK, for smart poster the latter should be an error too (smart poster cannot be empty), but again, for TNF = {4,5} it could be the case (though making little to no sense).

However, my question is why not to use a method, once we need to run an algorithm to parse the data into records (that might also fail). It doesn't seem like a good match for representing it with a property (array).

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

Received on Friday, 4 October 2019 06:37:09 UTC