WakeLockSentinel.released Attribute

The WakeLockSentinel object has a new attribute called `released` that indicates whether a sentinel has already been released. Its value is initially false, and it changes to true once a "release" event is dispatched.

Motivation

The new attribute helps web developers know when a lock has been released so that they do not need to keep track of them manually. See https://github.com/w3c/screen-wake-lock/issues/272 for the original discussion.

Specification

Editor's draft

Status in Chromium

Blink>WakeLock


Enabled by default (tracking bug) in:

  • Chrome for desktop release 87
  • Chrome for Android release 87
  • Android WebView release 87

Consensus & Standardization

After a feature ships in Chrome, the values listed here are not guaranteed to be up to date.

  • No signal
  • No signal
  • No signal
  • No signals

Owner

Last updated on 2020-10-25