下载地址:
链接:https://pan.baidu.com/s/1e7zh8pXhR5h_obipuaq3zA 密码:i4pg
使用方法:
//.dts文件中: declare namespace htmlDocx { export function asBlob(content:string); }
//.ts中引入: ///<reference path="./htmldocx/html-docx-js.d.ts"/>
//html页面: <!--docx--> <script src="./htmldocx/build/html-docx.js"></script>
let converted = htmlDocx.asBlob(downContent);//downContent为所需下载内容的HTML标签 saveAs(converted, "保存的文件名"+'.docx');