Skip to Content
Vue.js 2 Cookbook
book

Vue.js 2 Cookbook

by Andrea Passaglia
April 2017
Intermediate to advanced
454 pages
12h 51m
English
Packt Publishing
Content preview from Vue.js 2 Cookbook

How it works...

The core of our app is the <transition-group> tag. It manages all the buses identified by their key:

<transition-group tag="p" name="station">   <span v-for="bus in buses" :key="bus"></span> </transition-group>

Whenever a bus enters or leaves the scenes, a FLIP animation (see the Adding your own transition classes recipe) will be automatically triggered by Vue.

To fix ideas, let's say we have buses [1, 2, 3] and bus 1 leaves the scene. What happens next is that the properties of the first bus's <span> element will be memorized before the animation actually starts. So we may retrieve the following object describing the properties: ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Learning Vue.js 2

Learning Vue.js 2

Olga Filipova
Pro Vue.js 2

Pro Vue.js 2

Adam Freeman

Publisher Resources

ISBN: 9781786468093Supplemental Content