Re: [w3c/permissions] Definition of PermissionStatus lifetime (#266)

In #360, we are simplifying it to just: 

> A {{PermissionStatus}} object MUST NOT be garbage collected if it has an [=event listener=] whose type is `change`.

That capture the intent that this works:

```JS
(async () => {
  const perm = await navigator.permissions.query({ name: "geolocation" });
  perm.onchange = console.log;
  // bye bye perm... but not garbage collected
})();
```

-- 
Reply to this email directly or view it on GitHub:
https://github.com/w3c/permissions/issues/266#issuecomment-1033397210
You are receiving this because you are subscribed to this thread.

Message ID: <w3c/permissions/issues/266/1033397210@github.com>

Received on Wednesday, 9 February 2022 06:28:42 UTC