Skip to content

Destroy hook is called before transition finishes #80

Open
@antonisntoulis

Description

@antonisntoulis

Checks

Version

0.6.12

Description

Vue 3 built-in unMounted/beforeUnmount hooks get called before transitions have ended and it's sadly the expected behaviour.

Splide calls the destroy() method on its instance when the vue beforeUnmount hook gets called.

When we have a transition on our pages we can see the splide get destroyed(slides suddently lose styling ,positioning etc) before the page has finished transitioning and this is not ideal at all.

Reproduction Link

No response

Steps to Reproduce

  1. Create a vue app with router
  2. Have at least two pages with transitions
  3. Put a splide on one of the pages
  4. Navigate from the page with the splide to another one
    ...

Expected Behaviour

Splide should wait for the transitions to end before destroying.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions