在Vue组件的方法中,我读了这个代码,其中函数以这种方式定义
methods : {
onEditorChange({ editor, html, text }) {
console.log('editor change!', editor, html, text)
this.content = html
}
}
Run Code Online (Sandbox Code Playgroud)
我检查了代码,它正在工作.我们可以向这样的函数声明形式参数吗?您可以在https://github.com/surmon-china/vue-quill-editor中找到代码段.
Vue 中的 v-model 是一个内置功能,仅适用于少数选定标签吗?props 功能是否可以替代 v-model?