Firefox 91 for developers
=========================

This article provides information about the changes in Firefox 91 that will affect developers. Firefox 91 was released on August 10, 2021.

**Note:** See also Hopping on Firefox 91 on Mozilla Hacks.

Changes for web developers
--------------------------

### HTML

No changes

### CSS

* A fix to how the `@counter-style/pad` descriptor handles the negative sign (Firefox bug 1714445).
* The `-moz-tab-size` property has been unprefixed to the standard `tab-size`, and the prefixed version maintained as an alias (Firefox bug 737785).

#### Removals

* The non-standard `-moz-outline-radius` property has been removed (Firefox bug 1715984). The property has not been usable by web developers since Firefox 88, this completes the removal.
### JavaScript

* `Intl.DateTimeFormat.prototype.formatRange()` and `Intl.DateTimeFormat.prototype.formatRangeToParts()` are now supported in release builds. The `formatRange()` method returns a localized and formatted string for the range between two `Date` objects (e.g. "1/05/21 – 1/10/21"). The `formatRangeToParts()` method returns an array containing the locale-specific *parts* of a formatted date range (Firefox bug 1653024).
* The `Intl.DateTimeFormat() constructor` allows four new `timeZoneName` options for formatting how the timezone is displayed. These include the localized GMT formats `shortOffset` and `longOffset`, and the generic non-location formats `shortGeneric` and `longGeneric` (Firefox bug 1653024).
* The `Error() constructor` can now take the error `cause` as value in the `option` parameter.
 This allows code to catch errors and throw new/modified versions that retain the original error and stack trace (Firefox bug 1679653).
### HTTP

* The Gamepad API now requires a secure context (Firefox bug 1704005).
### APIs

#### DOM

* The Visual Viewport API is now enabled by default on Firefox desktop releases (it has been enabled on Firefox for Android since version 68).
 The API provides access to information describing the position of the visual viewport relative to the document, as well as to the window's content area.
 It also provides events that allow changes to the viewport to be monitored. (Firefox bug 1551302).
* The Gamepad API is now protected by `Feature-Policy: gamepad`.
 If disallowed by the Permission Policy, calls to `Navigator.getGamepads()` will throw a `SecurityError` `DOMException`,
 and the `gamepadconnected` and `gamepaddisconnected` events will not fire.
 The default `allowlist` is `*`; this default will be updated to `self` in a future release, in order to match the specification. (Firefox bug 1704005).
* `Window.clientInformation` has been added as an alias for `Window.navigator`, in order to match recent specification updates and improve compatibility with other major browsers (Firefox bug 1717072).
* Changing the playback speed of a media element (`<video>` or `<audio>`) using the `playbackRate` attribute now works when the media element is captured to a `MediaStream` or via `AudioContext.createMediaElementSource` (Firefox bug 1517199).
### WebDriver conformance (Marionette)

* Fixed a bug, which caused the commands `WebDriver:AcceptAlert` and `WebDriver:DismissAlert` to hang for user prompts as opened in a popup window (Firefox bug 1721982).
* Fixed an inappropriate handling of the `webSocketUrl` capability, which would return `true` if `webSocketUrl` was not supported (Firefox bug 1713775).
Older versions
--------------

* Firefox 90 for developers
* Firefox 89 for developers
* Firefox 88 for developers
* Firefox 87 for developers
* Firefox 86 for developers
* Firefox 85 for developers
* Firefox 84 for developers
* Firefox 83 for developers
* Firefox 82 for developers
* Firefox 81 for developers
* Firefox 80 for developers
* Firefox 79 for developers
* Firefox 78 for developers
* Firefox 77 for developers
* Firefox 76 for developers
* Firefox 75 for developers
* Firefox 74 for developers
* Firefox 73 for developers
* Firefox 72 for developers
* Firefox 71 for developers
* Firefox 70 for developers
* Firefox 69 for developers
* Firefox 68 for developers
* Firefox 67 for developers
* Firefox 66 for developers
* Firefox 65 for developers
* Firefox 64 for developers
* Firefox 63 for developers
* Firefox 62 for developers
* Firefox 61 for developers
* Firefox 60 for developers