react icon indicating copy to clipboard operation
react copied to clipboard

Bug: Event.composedPath() and Event.composed missing

Open Wiz1991 opened this issue 3 years ago • 0 comments

React version: 18.2.0

Steps To Reproduce

  1. Create any html element
  2. Add event listener
  3. Check if method and property exists

The current behavior

const ExampleComponent = () => {
    // composedPath is not a function
    return <div onClick={(e) => { e.composedPath() }}></div>
}

The expected behavior

const ExampleComponent = () => {
    // composedPath should be found, as well as composed property
    return <div onClick={(e) => { e.composedPath() }}></div>
}

MDN Docs for the relevant feature: https://developer.mozilla.org/en-US/docs/Web/API/Event/composedPath

Wiz1991 avatar Aug 31 '22 15:08 Wiz1991