November 2017
Beginner to intermediate
398 pages
8h 42m
English
When the card is played, which means removed from the hand card list, it triggers a leaving animation. We would like to wait for it to finish before continuing. Fortunately, the transition and transition-group components emit events.
The one we need here is the 'after-leave' event, but there are other events corresponding to each phase of the transitions--'before-enter', 'enter', 'after-enter', and so on.
<transition-group name="card" tag="div" class="cards" @after- leave="handleLeaveTransitionEnd">
methods: { // ... handleLeaveTransitionEnd ...Read now
Unlock full access