CustomEvent Bug

Issue #19861977 • Assigned to wptdomtri


Павел З.
Dec 7, 2018
This issue is public.
Found in
  • Microsoft Edge
  • Internet Explorer
Standard affected
DOM Standard

Reported by 2 people

Sign in to watch or report this issue.

Steps to reproduce

CustomEvent trigger on first handler instead of the desired after back to page and download. Bug is reproduced in all Edge/IE versions.

document.addEventListener('bug', function(e) {
    console.log('bug!', e);
document.addEventListener('test', function() {
document.addEventListener('click', function() {
    var event = document.createEvent('CustomEvent');
    event.initCustomEvent('test', true, true, {});

See this to reproduce:


0 attachments

    Comments and activity

    • Microsoft Edge Team

      Changed Assigned To to “Veerabhadra r.”

    • Hi, Thanks for reporting your feedback, We tested it and cannot reproduce this issue. Could you please provide more information such as any screenshots or related docs that will help us to investigate further. Also suggesting you to check the build.
      Build details:
      Microsoft Edge 44.17763.1.0
      Microsoft EdgeHTML 18.17763

      The MS Edge Team

    • Microsoft Edge Team

      Changed Assigned To to “wptdomtri”

    • Hi,

      Our team also stumbled on this bug this week. We noticed that CustomEvent instances were dispatched to the wrong handlers on some user browsers. By looking at our logs, we were able to pin it down to Edge (up to Edge 18 according to our logs) and Internet Explorer.

      Using the page given above, I can reproduce it 100%, but the instructions seem to be a bit misleading.

      Steps to reproduce:

      1. Using Edge, navigate to
      2. Click on the download link labeled as “Step 2” (you don’t need to save the file, clicking the link is enough)
      3. Click anywhere in the blank space of the document.

      Expected result: “normal”
      Observed result: “bug!”

      (I’m using Edge 17.17134 here.)

      I suspect this bug can be triggered in other conditions too, and that quites severely impact the usefulness of CustomEvent, making us unable to trust it at all.

    • Thanks, Fabien B!
      I forgot about step 3 - Click anywhere in the blank space of the document.

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

    Sign in