|
|
@ -1,10 +1,10 @@
|
|
|
|
const createRefHooks = fn => {
|
|
|
|
const createRefHooks = fn => {
|
|
|
|
return {
|
|
|
|
return {
|
|
|
|
onVnodeBeforeMount: vnode => {
|
|
|
|
onVnodeBeforeMount: vnode => {
|
|
|
|
fn(vnode.component || vnode.el, vnode.key);
|
|
|
|
fn((vnode.component && vnode.component.ctx) || vnode.el, vnode.key);
|
|
|
|
},
|
|
|
|
},
|
|
|
|
onVnodeUpdated: vnode => {
|
|
|
|
onVnodeUpdated: vnode => {
|
|
|
|
fn(vnode.component || vnode.el, vnode.key);
|
|
|
|
fn((vnode.component && vnode.component.ctx) || vnode.el, vnode.key);
|
|
|
|
},
|
|
|
|
},
|
|
|
|
onVnodeUnmounted: vnode => {
|
|
|
|
onVnodeUnmounted: vnode => {
|
|
|
|
fn(null, vnode.key);
|
|
|
|
fn(null, vnode.key);
|
|
|
|