使用方法:
html2canvas($(".meeting-contractor-view-content"), {
onrendered: function (canvas) {
var url = canvas.toDataURL();//图片地址
$item.find("img").attr("src", url);
self.len++;
var set = setTimeout(function () {
self.viewinit();
clearTimeout(set);
}, 1000);
},
1920,
height: 1000
})
js库下载地址:https://github.com/pijiahao/Demo-Project