wxml-to-canvas组件renderToCanvas绘制海报之后怎么把海报关掉啊?
renderToCanvas() {
const wxml = getWxml(this.data.info);//获取template
const style = getStyle(this.data.info)//获取canvas
const p1 = this.widget.renderToCanvas({ wxml, style })
p1.then((res) => {
this.container = res
this.extraImage()
})
},
extraImage() {
const p2 = this.widget.canvasToTempFilePath()
p2.then(res => {
this.setData({
src: res.tempFilePath,
width: this.container.layoutBox.width,
height: this.container.layoutBox.height
})
})
},
只有这两个方法没看到有关闭海报的方法