知道了, 在 editorCtx.insertImage 之前先处理好图片再调用 editorCtx.insertImage,原来操作按钮和编辑器展示内容是分开的。 uni.chooseImage({ count: 1, success: (res) => { // 在这里先处理上传图片 this.editorCtx.insertImage({ src: res.tempFilePaths[0], alt: '图像', success: function() { console.log('insert image success') } }) } })
1 个回复
y***@gmail.com (作者)
知道了,
在
editorCtx.insertImage
之前先处理好图片再调用 editorCtx.insertImage,原来操作按钮和编辑器展示内容是分开的。