The read-only released property of the WakeLockSentinel interface returns a boolean that indicates whether a WakeLockSentinel has been released yet.
On this page
WakeLockSentinel: released property
Syntax
js
const released = sentinel.released
Value
A boolean value, that is false until the WakeLockSentinel has been released (either through a call to WakeLockSentinel.release() or because the lock has been released automatically) and the release event has been emitted, after which it becomes true and no longer changes.
Examples
This example shows how released's value changes within a WakeLockSentinel's life cycle.
js
const sentinel = await navigator.wakeLock.request("screen");
console.log(sentinel.released); // Logs "false"
sentinel.onrelease = () => {
  console.log(sentinel.released); // Logs "true"
};
await sentinel.release();
Specifications
| Specification | 
|---|
| Screen Wake Lock API # dom-wakelocksentinel-released | 
Browser compatibility
| Desktop | Mobile | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Chrome | Edge | Firefox | Internet Explorer | Opera | Safari | WebView Android | Chrome Android | Firefox for Android | Opera Android | Safari on IOS | Samsung Internet | |
| released | 87 | 87 | No | No | 73 | 16.4 | 87 | 87 | No | 62 | 16.4 | 14.0 | 
© 2005–2023 MDN contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
 https://developer.mozilla.org/en-US/docs/Web/API/WakeLockSentinel/released