Intent to unship: KeyboardEvent.initKeyEvent

Skip to first unread message

Masayuki Nakano

Aug 10, 2021, 12:08:14 AM8/10/21
to dev-platform
Summary: This is legacy initializer of KeyboardEvent, but this is
implemented only by Gecko and was dropped even from DOM Level 2 spec.
There is another initiailizer, `initKeyboardEvent`, and in these days,
web developers can use KeyboardEvent constructor for initializing all
attributes with simpler syntax. So, nobody must require this unless
somebody uses web apps which can run only on Gecko.


Standard: N/A

Platform coverage: all


DevTools bug: N/A

Other browsers: Nobody has implemented this except us.

web-platform-tests: included into the second patch which tests its type.

Security and Privacy: It is one of the ways to detect Firefox, but other
Gecko specific API can use for same purpose. So, nothing must be changed
in the wild.

Masayuki Nakano <>
Working on DOM, Events, editor and IME handling for Gecko

Masayuki Nakano

Aug 10, 2021, 12:10:56 AM8/10/21
to dev-platform
On 21/08/10 13:08, Masayuki Nakano wrote:

Oops, `dom.keyboardevent.init_key_event.enabled` can re-enable it for a while.

Masayuki Nakano

Sep 1, 2021, 2:46:43 AM9/1/21
to dev-platform
`KeyboardEvent.initKeyEvent` stays there only in addons for a while, but
currently, it'll be unshipped in the web.

The reason is, some addons use it without feature detection like web
content because they can assume specific path runs only in specific browser.

This was done in

Reply all
Reply to author
0 new messages