Skip to content
This repository was archived by the owner on Dec 16, 2021. It is now read-only.
This repository was archived by the owner on Dec 16, 2021. It is now read-only.

bug: ReactTransitionEvents doesn't work in supported browsers #396

Open

Description

@Hotell

I'm submitting a ... (check one with "x")

[x] bug report
[ ] feature request

Current behavior

Issue is that you are registering TransitionEnd / AnimationEnd in browsers that support ontransitionend/onanimationend -> this leads that not existent event is registered in supported browsers and things don't work.

Expected/New behavior

register proper events cross-browser

Minimal reproduction of the problem with instructions

For instance react-redux-toaster is using ReactTransitionEvents for registering transition events.

With React works without issues

preact-compat-issue-with-events-react

With Preact, the proper events are not called so it is not removed from store and stays in DOM

What is the motivation / use cases?
Some react libs are using ReactTransitionEvents for critical functionality ( like cleaning up store )

Preact-compat version: 3.16.0

Browser:
Chrome, FF, Edge, Safari

I can send PR if you're ok with that

Thanks

Activity

  1. thomas-p-wilson commented on Jun 10, 2017

    @thomas-p-wilson

    Am having the exact same issue here, also with react-redux-toastr in fact.

  2. developit commented on Jun 10, 2017

    @developit
    Member
  3. thomas-p-wilson commented on Jun 10, 2017

    @thomas-p-wilson
  4. thomas-p-wilson commented on Jun 10, 2017

    @thomas-p-wilson
  5. thomas-p-wilson commented on Jun 10, 2017

    @thomas-p-wilson
  6. deepkolos commented on Nov 12, 2019

    @deepkolos

    have the same issue

    图片

    the first one is created by preact , won't trigger when transitionend
    the second is created by addEventlistener, will trigger when transitionend

    i use ontransitionend as workround...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions