W3C home > Mailing lists > Public > public-webrtc-logs@w3.org > October 2022

Re: [mediacapture-screen-share] Address nullability of DisplayMediaStreamOptions.controller (#236)

From: Jan-Ivar Bruaroey via GitHub <sysbot+gh@w3.org>
Date: Sat, 01 Oct 2022 14:46:42 +0000
To: public-webrtc-logs@w3.org
Message-ID: <issue_comment.created-1264385914-1664635600-sysbot+gh@w3.org>
To understand the general advice here better, is it meant to also apply to dictionary arguments to constructors?

I notice in both this and the AddEventListenerOptions example, there were no corresponding `readonly` attribute exposing the internal slot for JS to read back what was set, if anything (is the advice for such an attribute to still yield `null`, or `undefined`)? Interfaces don't support missing AFAIK). If the answer is the readonly attribute should be `null`, then not accepting `null` as input would seem mildly unexpected perhaps, and also break any (encouraged or discouraged?) constructor duplicator patterns popularized by Events., and used in places like RTCSessionDescription E.g.
const a = new Foo({bar: new Bar()})
const b = new Foo({});
const c = b.bar; // null or undefined?
const d = new Foo(b); // b is member equivalent and has toJSON(), but TypeError over b.bar being null?

GitHub Notification of comment by jan-ivar
Please view or discuss this issue at https://github.com/w3c/mediacapture-screen-share/issues/236#issuecomment-1264385914 using your GitHub account

Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Saturday, 1 October 2022 14:46:44 UTC

This archive was generated by hypermail 2.4.0 : Saturday, 6 May 2023 21:19:59 UTC