mirror of
https://github.com/jaywcjlove/reference.git
synced 2025-06-18 05:01:21 +08:00
doc: update vue2.md
. (#5) 81001e2594
This commit is contained in:
@ -523,7 +523,7 @@
|
||||
|
||||
|
||||
|
||||
<table><thead><tr><th align="left">:-</th><th align="left">:-</th></tr></thead><tbody><tr><td align="left"><code>data</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#data">#</a></td></tr><tr><td align="left"><code>props</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#props">#</a></td></tr><tr><td align="left"><code>propsData</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#propsData">#</a></td></tr><tr><td align="left"><code>computed</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#computed">#</a></td></tr><tr><td align="left"><code>methods</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#methods">#</a></td></tr><tr><td align="left"><code>watch</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#watch">#</a></td></tr></tbody></table>
|
||||
<table><thead><tr><th align="left">:-</th><th align="left">:-</th></tr></thead><tbody><tr><td align="left"><code>data</code></td><td align="left">实例的数据对象 <a href="https://v2.cn.vuejs.org/v2/api/#data">#</a></td></tr><tr><td align="left"><code>props</code></td><td align="left">接收来自父组件的数据 <a href="https://v2.cn.vuejs.org/v2/api/#props">#</a></td></tr><tr><td align="left"><code>propsData</code></td><td align="left">创建实例时传递 props <a href="https://v2.cn.vuejs.org/v2/api/#propsData">#</a></td></tr><tr><td align="left"><code>computed</code></td><td align="left">计算属性将被混入到 Vue 实例中 <a href="https://v2.cn.vuejs.org/v2/api/#computed">#</a></td></tr><tr><td align="left"><code>methods</code></td><td align="left">将被混入到 Vue 实例中 <a href="https://v2.cn.vuejs.org/v2/api/#methods">#</a></td></tr><tr><td align="left"><code>watch</code></td><td align="left">对象键是观察的表达式,值是回调函数 <a href="https://v2.cn.vuejs.org/v2/api/#watch">#</a></td></tr></tbody></table>
|
||||
</div></div></div><div class="wrap"><div class="wrap-header h3wrap"><h3 id="dom"><a aria-hidden="true" tabindex="-1" href="#dom"><span class="icon icon-link"></span></a>DOM</h3><div class="wrap-body">
|
||||
|
||||
|
||||
@ -606,7 +606,7 @@
|
||||
|
||||
|
||||
|
||||
<table><thead><tr><th align="left">:-</th><th align="left">:-</th></tr></thead><tbody><tr><td align="left"><code>beforeCreate</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#beforeCreate">#</a></td></tr><tr><td align="left"><code>created</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#created">#</a></td></tr><tr><td align="left"><code>beforeMount</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#beforeMount">#</a></td></tr><tr><td align="left"><code>mounted</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#mounted">#</a></td></tr><tr><td align="left"><code>beforeUpdate</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#beforeUpdate">#</a></td></tr><tr><td align="left"><code>updated</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#updated">#</a></td></tr><tr><td align="left"><code>activated</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#activated">#</a></td></tr><tr><td align="left"><code>deactivated</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#deactivated">#</a></td></tr><tr><td align="left"><code>beforeDestroy</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#beforeDestroy">#</a></td></tr><tr><td align="left"><code>destroyed</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#destroyed">#</a></td></tr><tr><td align="left"><code>errorCaptured</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#errorCaptured">#</a></td></tr></tbody></table>
|
||||
<table><thead><tr><th align="left">:-</th><th align="left">:-</th></tr></thead><tbody><tr><td align="left"><code>beforeCreate</code></td><td align="left">实例初始化之后 <a href="https://v2.cn.vuejs.org/v2/api/#beforeCreate">#</a></td></tr><tr><td align="left"><code>created</code></td><td align="left">实例创建完成后被立即同步调用 <a href="https://v2.cn.vuejs.org/v2/api/#created">#</a></td></tr><tr><td align="left"><code>beforeMount</code></td><td align="left">在挂载开始之前被调用 <a href="https://v2.cn.vuejs.org/v2/api/#beforeMount">#</a></td></tr><tr><td align="left"><code>mounted</code></td><td align="left">实例被挂载后调用 <a href="https://v2.cn.vuejs.org/v2/api/#mounted">#</a></td></tr><tr><td align="left"><code>beforeUpdate</code></td><td align="left">数据改变后 DOM 更新之前调用 <a href="https://v2.cn.vuejs.org/v2/api/#beforeUpdate">#</a></td></tr><tr><td align="left"><code>updated</code></td><td align="left">数据更改更新完毕之后被调用 <a href="https://v2.cn.vuejs.org/v2/api/#updated">#</a></td></tr><tr><td align="left"><code>activated</code></td><td align="left">keep-alive 缓存组件激活时调用 <a href="https://v2.cn.vuejs.org/v2/api/#activated">#</a></td></tr><tr><td align="left"><code>deactivated</code></td><td align="left">keep-alive 缓存的组件失活时调用 <a href="https://v2.cn.vuejs.org/v2/api/#deactivated">#</a></td></tr><tr><td align="left"><code>beforeDestroy</code></td><td align="left">实例销毁之前调用 <a href="https://v2.cn.vuejs.org/v2/api/#beforeDestroy">#</a></td></tr><tr><td align="left"><code>destroyed</code></td><td align="left">实例销毁后调用 <a href="https://v2.cn.vuejs.org/v2/api/#destroyed">#</a></td></tr><tr><td align="left"><code>errorCaptured</code></td><td align="left">来自后代组件的错误时被调用 <a href="https://v2.cn.vuejs.org/v2/api/#errorCaptured">#</a></td></tr></tbody></table>
|
||||
</div></div></div><div class="wrap"><div class="wrap-header h3wrap"><h3 id="资源"><a aria-hidden="true" tabindex="-1" href="#资源"><span class="icon icon-link"></span></a>资源</h3><div class="wrap-body">
|
||||
|
||||
|
||||
@ -629,7 +629,7 @@
|
||||
|
||||
|
||||
|
||||
<table><thead><tr><th align="left">:-</th><th align="left">:-</th></tr></thead><tbody><tr><td align="left"><code>directives</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#directives">#</a></td></tr><tr><td align="left"><code>filters</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#filters">#</a></td></tr><tr><td align="left"><code>components</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#components">#</a></td></tr></tbody></table>
|
||||
<table><thead><tr><th align="left">:-</th><th align="left">:-</th></tr></thead><tbody><tr><td align="left"><code>directives</code></td><td align="left">包含 Vue 实例可用指令的哈希表 <a href="https://v2.cn.vuejs.org/v2/api/#directives">#</a></td></tr><tr><td align="left"><code>filters</code></td><td align="left">包含 Vue 实例可用过滤器的哈希表 <a href="https://v2.cn.vuejs.org/v2/api/#filters">#</a></td></tr><tr><td align="left"><code>components</code></td><td align="left">包含 Vue 实例可用组件的哈希表 <a href="https://v2.cn.vuejs.org/v2/api/#components">#</a></td></tr></tbody></table>
|
||||
</div></div></div><div class="wrap"><div class="wrap-header h3wrap"><h3 id="组合"><a aria-hidden="true" tabindex="-1" href="#组合"><span class="icon icon-link"></span></a>组合</h3><div class="wrap-body">
|
||||
|
||||
|
||||
@ -656,7 +656,7 @@
|
||||
|
||||
|
||||
|
||||
<table><thead><tr><th align="left">:-</th><th align="left">:-</th></tr></thead><tbody><tr><td align="left"><code>parent</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#parent">#</a></td></tr><tr><td align="left"><code>mixins</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#mixins">#</a></td></tr><tr><td align="left"><code>extends</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#extends">#</a></td></tr><tr><td align="left"><code>provide / inject</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#provide-inject">#</a></td></tr></tbody></table>
|
||||
<table><thead><tr><th align="left">:-</th><th align="left">:-</th></tr></thead><tbody><tr><td align="left"><code>parent</code></td><td align="left">指定已创建的实例之父实例 <a href="https://v2.cn.vuejs.org/v2/api/#parent">#</a></td></tr><tr><td align="left"><code>mixins</code></td><td align="left">接收一个混入对象的数组 <a href="https://v2.cn.vuejs.org/v2/api/#mixins">#</a></td></tr><tr><td align="left"><code>extends</code></td><td align="left">声明扩展另一个组件 <a href="https://v2.cn.vuejs.org/v2/api/#extends">#</a></td></tr><tr><td align="left"><code>provide/inject</code></td><td align="left">祖组件向所有子孙后代注入依赖 <a href="https://v2.cn.vuejs.org/v2/api/#provide-inject">#</a></td></tr></tbody></table>
|
||||
</div></div></div><div class="wrap"><div class="wrap-header h3wrap"><h3 id="其它"><a aria-hidden="true" tabindex="-1" href="#其它"><span class="icon icon-link"></span></a>其它</h3><div class="wrap-body">
|
||||
|
||||
|
||||
@ -805,7 +805,7 @@
|
||||
|
||||
|
||||
|
||||
<table><thead><tr><th align="left">:-</th><th align="left">:-</th></tr></thead><tbody><tr><td align="left"><code>vm.$on</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#vm-on">#</a></td></tr><tr><td align="left"><code>vm.$once</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#vm-once">#</a></td></tr><tr><td align="left"><code>vm.$off</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#vm-off">#</a></td></tr><tr><td align="left"><code>vm.$emit</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#vm-emit">#</a></td></tr></tbody></table>
|
||||
<table><thead><tr><th align="left">:-</th><th align="left">:-</th></tr></thead><tbody><tr><td align="left"><code>vm.$on</code></td><td align="left">监听当前实例上的自定义事件 <a href="https://v2.cn.vuejs.org/v2/api/#vm-on">#</a></td></tr><tr><td align="left"><code>vm.$once</code></td><td align="left">监听一个自定义事件,只触发一次 <a href="https://v2.cn.vuejs.org/v2/api/#vm-once">#</a></td></tr><tr><td align="left"><code>vm.$off</code></td><td align="left">移除自定义事件监听器 <a href="https://v2.cn.vuejs.org/v2/api/#vm-off">#</a></td></tr><tr><td align="left"><code>vm.$emit</code></td><td align="left">触发当前实例上的事 <a href="https://v2.cn.vuejs.org/v2/api/#vm-emit">#</a></td></tr></tbody></table>
|
||||
</div></div></div><div class="wrap"><div class="wrap-header h3wrap"><h3 id="实例方法--生命周期"><a aria-hidden="true" tabindex="-1" href="#实例方法--生命周期"><span class="icon icon-link"></span></a>实例方法 / 生命周期</h3><div class="wrap-body">
|
||||
|
||||
|
||||
@ -832,7 +832,7 @@
|
||||
|
||||
|
||||
|
||||
<table><thead><tr><th align="left">:-</th><th align="left">:-</th></tr></thead><tbody><tr><td align="left"><code>vm.$mount</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#vm-mount">#</a></td></tr><tr><td align="left"><code>vm.$forceUpdate</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#vm-forceUpdate">#</a></td></tr><tr><td align="left"><code>vm.$nextTick</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#vm-nextTick">#</a></td></tr><tr><td align="left"><code>vm.$destroy</code></td><td align="left"><a href="https://v2.cn.vuejs.org/v2/api/#vm-destroy">#</a></td></tr></tbody></table>
|
||||
<table><thead><tr><th align="left">:-</th><th align="left">:-</th></tr></thead><tbody><tr><td align="left"><code>vm.$mount</code></td><td align="left">手动地挂载一个未挂载的实例 <a href="https://v2.cn.vuejs.org/v2/api/#vm-mount">#</a></td></tr><tr><td align="left"><code>vm.$forceUpdate</code></td><td align="left">迫使 Vue 实例重新渲染 <a href="https://v2.cn.vuejs.org/v2/api/#vm-forceUpdate">#</a></td></tr><tr><td align="left"><code>vm.$nextTick</code></td><td align="left">回调延迟执行 <a href="https://v2.cn.vuejs.org/v2/api/#vm-nextTick">#</a></td></tr><tr><td align="left"><code>vm.$destroy</code></td><td align="left">完全销毁一个实例 <a href="https://v2.cn.vuejs.org/v2/api/#vm-destroy">#</a></td></tr></tbody></table>
|
||||
</div></div></div><div class="wrap row-span-2"><div class="wrap-header h3wrap"><h3 id="指令-1"><a aria-hidden="true" tabindex="-1" href="#指令-1"><span class="icon icon-link"></span></a>指令</h3><div class="wrap-body">
|
||||
<!--rehype:wrap-class=row-span-2-->
|
||||
|
||||
|
Reference in New Issue
Block a user