Edge doesn't throw for addEventListener('x', false)

Not reproducible Issue #10397104

Details

Author
Travis L.
Created
Jan 4, 2017
Privacy
This issue is public.
Found in
  • Microsoft Edge
  • Internet Explorer
  • Chrome
Standard affected
Web IDL

Found in build #
15.14996
Reports
Reported by 1 person

Sign in to watch or report this issue.

Steps to reproduce

Per WebIDL, Edge should be throwing when the 2nd parameter to addEventListener is false (like Firefox does today).

Note Chrome also does not throw, but will be changing behavior to match eventually.

document.addEventListener('x', false);

expected: throws a TypeError
actual: registers a listener? Silently fails?

Same goes for removeEventListener.

Attachments

0 attachments

    Comments and activity

    • Note, this issue was found by BorisZ of Mozilla and filed on his behalf.

    • Microsoft Edge Team

      Changed Assigned To to “Brad E.”

      Changed Status to “Not reproducible”

    • Hello,

      Thank you for providing this information about the issue. The problem appears to be fixed as we cannot replicate it in Edge 14393 public stable release and the behavior exhibited matches the other browsers. Please reopen this case if you have new information for us to consider.

      Best Wishes,
      The MS Edge Team

    • Edge 15 throws on document.removeEventListener(element, undefined);. Chrome does not. This manifested itself as a bug in our video player today when testing on Edge 15 with an upcoming release. Is this expected behavior?

    • … same with intersectionObserver.unobserve(element) when intersectionObserver.observe(element) has not been called.

    You need to sign in to your Microsoft account to add a comment.

    Sign in