Re: [wake-lock] Losing reference to a WakeLock object is a bug or intended behavior (#199)

Actually, we could make this work with less changes to the current API

```webidl
[Constructor(WakeLockType type), SecureContext, Exposed=(DedicatedWorker, Window)]
interface WakeLock  {
  [Exposed=Window] static Promise<PermissionState> requestPermission(WakeLockType type);
  readonly attribute WakeLockType type;

  // Promise never resolves, so will fail or be aborted
  // In the future it could resolve if a timeout is set as part of options
  Promise<void> request(optional WakeLockRequestOptions options);
};
```

-- 
GitHub Notification of comment by kenchris
Please view or discuss this issue at https://github.com/w3c/wake-lock/issues/199#issuecomment-488263402 using your GitHub account

Received on Wednesday, 1 May 2019 11:44:49 UTC