@@ -102,14 +102,17 @@ const draggableComponent = defineComponent({
102
102
render ( ) {
103
103
const { $slots, $attrs, tag, componentData } = this ;
104
104
const renderContext = computeRenderContext ( { $slots, tag } ) ;
105
+ this . renderContext = renderContext ;
106
+ this . noneFunctionalComponentMode = renderContext . noneFunctional ;
105
107
const attributes = getComponentAttributes ( { $attrs, componentData } ) ;
106
108
107
- const mainNode = h ( renderContext . tag , attributes , renderContext . children ) ;
109
+ if ( renderContext . noneFunctional && renderContext . transitionMode ) {
110
+ throw new Error (
111
+ `Transition-group inside component is not supported. Please alter tag value or remove transition-group. Current tag value: ${ tag } `
112
+ ) ;
113
+ }
108
114
109
- this . renderContext = renderContext ;
110
- this . noneFunctionalComponentMode =
111
- renderContext . externalComponent && typeof mainNode . type !== "function" ;
112
- return mainNode ;
115
+ return h ( renderContext . tag , attributes , renderContext . children ) ;
113
116
} ,
114
117
115
118
created ( ) {
@@ -121,18 +124,8 @@ const draggableComponent = defineComponent({
121
124
} ,
122
125
123
126
mounted ( ) {
124
- const {
125
- tag,
126
- $attrs,
127
- rootContainer,
128
- noneFunctionalComponentMode,
129
- renderContext : { transitionMode }
130
- } = this ;
131
- if ( noneFunctionalComponentMode && transitionMode ) {
132
- throw new Error (
133
- `Transition-group inside component is not supported. Please alter tag value or remove transition-group. Current tag value: ${ tag } `
134
- ) ;
135
- }
127
+ const { $attrs, rootContainer } = this ;
128
+
136
129
const sortableOptions = createSortableOption ( {
137
130
$attrs,
138
131
callBackBuilder : {
0 commit comments