插入以下模板代码
<editor id=”editor” class=”ql-container” :placeholder=”placeholder” @ready=”onEditorReady”></editor>
JS代码部分如下
onEditorReady(){
uni.createSelectorQuery().select(‘#editor’).context((res) => {
this.editorCtx = res.context
this.editorCtx.setContents({
html:this.EditGoodsDetail.content //this.EditGoodsDetail.content为赋值内容。
})
}).exec()
}
发表回复
要发表评论,您必须先登录。