Browse Source

remove el

dev
Evan You 9 years ago
parent
commit
2aecd90214
  1. 10
      src/compiler/codegen/directives/el.js

10
src/compiler/codegen/directives/el.js

@ -1,10 +0,0 @@
export function ref (el, dir) {
if (!el.hooks) el.hooks = {}
const code = `$refs["${dir.arg}"]=vnode.elm || vnode.data.child`
if (el.hooks.insert) {
el.hooks.insert = el.hooks.insert
.replace(/^function\(vnode\)\{(.*)\}$/, `function(vnode){$1;${code}}`)
} else {
el.hooks.insert = `function(vnode){${code}}`
}
}
Loading…
Cancel
Save