From aea2beede72742bc1a563828fd66e5cb7b39d4eb Mon Sep 17 00:00:00 2001 From: Anton Bershanskiy <45960703+bershanskiy@users.noreply.github.com> Date: Mon, 14 Sep 2026 21:55:09 +0300 Subject: [PATCH] [WebExtensions] alarms.create() argument persistAcrossSessons --- .../mozilla/add-ons/webextensions/api/alarms/create/index.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/files/en-us/mozilla/add-ons/webextensions/api/alarms/create/index.md b/files/en-us/mozilla/add-ons/webextensions/api/alarms/create/index.md index a8124fcf7b2322e..e7fd3b18e4387db 100644 --- a/files/en-us/mozilla/add-ons/webextensions/api/alarms/create/index.md +++ b/files/en-us/mozilla/add-ons/webextensions/api/alarms/create/index.md @@ -43,6 +43,8 @@ browser.alarms.create( - : `double`. The time the alarm will fire first, given as minutes from the time the alarm is set. If you specify `delayInMinutes`, don't specify `when`. - `periodInMinutes` {{optional_inline}} - : `double`. If this is specified, the alarm will fire again every `periodInMinutes` after its initial firing. If you specify this value you may omit both `when` and `delayInMinutes`, and the alarm will then fire initially after `periodInMinutes`. If `periodInMinutes` is not specified, the alarm will only fire once. + - `persistAcrossSessions` {{optional_inline}} + - : `boolean`. Whether alarm should persist across (profile) browsing sessions. Set this to `true` to persist alarm until the extension updates. Set to `false` to clear alarm when the extension is reloaded or updated or the browser restarts. If browser does not support profiles, then browsing session lasts from the moment the first browsing window opens until the last one closes. If browser supports profiles, then closing all windows belonging to the same (non-incognito) profile will terminate the profile browsing session, even if another profile has an active browsing session. As of September 2026, only Chrome 150+ supports this attribute, but other browsers may implement it later. In Chrome, this attribute defaults to `true` to match prior behavior. Other browsers, namely Firefox, may implement this attribute with default value of `false` to match current behavior (Firefox clears alarms across sessions). See [this discussion](https://github.com/w3c/webextensions/issues/406) for details. ### Return value