File tree Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -23,17 +23,30 @@ Based on and offering all features of [Sortable.js](https://github.com/RubaXa/So
23
23
* Full support of [ Sortable.js] ( https://github.com/RubaXa/Sortable ) features
24
24
* Keeps in sync view model and view
25
25
* No jquery dependency
26
+ * Plays nicely with Vue.js 2.0 transition-group
26
27
27
28
##For Vue.js 2.0
28
29
29
30
Use draggable component:
30
31
32
+ Tipical use:
31
33
``` html
32
34
<draggable :list =" list" :options =" {group:'people'}" @start =" dragging=true" @end =" dragging=false" >
33
35
<div v-for =" element in list" >{{element.name}}</div >
34
36
</draggable >
35
37
```
36
38
39
+ With ` transition-group ` :
40
+ ``` html
41
+ <draggable :list =" list" >
42
+ <transition-group >
43
+ <div v-for =" element in list" :key =" element.id" >
44
+ {{element.name}}
45
+ </div >
46
+ </transition-group >
47
+ </draggable >
48
+ ```
49
+
37
50
### Props
38
51
#### list
39
52
Type: ` Array ` <br >
You can’t perform that action at this time.
0 commit comments