您可以使用回调来获取类似于 react 的引用,在 vue2.x 中
You can use the callback to get a reference like react.
$ npm install vue-ref --saveimport ref from 'vue-ref'
Vue.use(ref)
this.dom = c">hello
this.child = c">
{...}">{{ n }} | Property | Description | Type |
|---|---|---|
| v-ref | a callback function | function(dom | vnode, key) |
In this callback function, you should not change any reactive data. Otherwise the render will enter an infinite loop.
暂无开放 Issues,或尚未同步最近议题。