- From: Adam Bergkvist <adam.bergkvist@ericsson.com>
- Date: Tue, 18 Aug 2015 08:39:01 +0000
- To: "public-script-coord@w3.org" <public-script-coord@w3.org>
- CC: Jan-Ivar Bruaroey <jib@mozilla.com>
Hi In the WebRTC WG, we have the getUserMedia() function where the script can specify which types of media it wants to request with a dictionary. For example: navigator.mediaDevices.getUserMedia({ "audio": true, "video": true}); We currently reject with a NotSupportedError if the script doesn't specify at least one media type (e.g. an empty dictionary). We recently had a discussion about rejecting with a TypeError instead. The reason is that since the required keyword was introduced, there's a way to specify that not all Objects can represent a dictionary since there can be rules regarding what members that need to be present. We don't have a keyword to express that "at least one of these members need to be present", but we're expressing that in prose instead. We would very much appreciate your input on this. Thanks /Adam
Received on Tuesday, 18 August 2015 08:39:29 UTC