| 3273 | } |
| 3274 | |
| 3275 | function createComponentInstanceForVnode ( |
| 3276 | vnode, // we know it's MountedComponentVNode but flow doesn't |
| 3277 | parent // activeInstance in lifecycle state |
| 3278 | ) { |
| 3279 | var options = { |
| 3280 | _isComponent: true, |
| 3281 | _parentVnode: vnode, |
| 3282 | parent: parent |
| 3283 | }; |
| 3284 | // check inline-template render functions |
| 3285 | var inlineTemplate = vnode.data.inlineTemplate; |
| 3286 | if (isDef(inlineTemplate)) { |
| 3287 | options.render = inlineTemplate.render; |
| 3288 | options.staticRenderFns = inlineTemplate.staticRenderFns; |
| 3289 | } |
| 3290 | return new vnode.componentOptions.Ctor(options) |
| 3291 | } |
| 3292 | |
| 3293 | function installComponentHooks (data) { |
| 3294 | var hooks = data.hook || (data.hook = {}); |