如何从二维数组生成 pdf,如下所述,在 JavaScript Sample Array var datasets=[[1.0,199.6],[2.0,205.05],[3.0,283.6],[4.0,220.15],[5.0,313.05]] ;
Here's a client side solution for generating PDF files using JavaScript only.
Code:
var data = [[1.0,199.6],[2.0,205.05],[3.0,283.6],[4.0,220.15],[5.0,313.05]];
var doc = new jsPDF();
doc.setFontSize(40);
doc.text(35, 25, data.map(function(e){ return e.join("\t"); }).join("\n"));
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.