W3C home > Mailing lists > Public > public-device-apis-log@w3.org > September 2020

Re: [screen-wake-lock] explainer: Expand on why WakeLock.request() still requires an argument. (#288)

From: Raphael Kubo da Costa via GitHub <sysbot+gh@w3.org>
Date: Wed, 23 Sep 2020 14:42:33 +0000
To: public-device-apis-log@w3.org
Message-ID: <issue_comment.created-697468642-1600872151-sysbot+gh@w3.org>
The way I see it is that defaults would be fine if we had something like `request(type, options)` and `options` was optional. If we were to add more values to `WakeLockType` such as "system" and others, having `navigator.wakeLock.request()` behave like `navigator.wakeLock.request("screen")` feels like something we'd do just to maintain backwards compatibility -- i.e. would there be any other reason to make the default "screen" at that point?

GitHub Notification of comment by rakuco
Please view or discuss this issue at https://github.com/w3c/screen-wake-lock/pull/288#issuecomment-697468642 using your GitHub account

Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Wednesday, 23 September 2020 14:42:34 UTC

This archive was generated by hypermail 2.4.0 : Monday, 4 July 2022 12:47:58 UTC