evidenceprime / html-docx-js

Converts HTML documents to DOCX in the browser
http://evidenceprime.github.io/html-docx-js/
MIT License
1.05k stars 285 forks source link

Include page border in docx file feature #118

Open josongvmtechphp opened 4 years ago

josongvmtechphp commented 4 years ago

This is a new feature of this tool. I tried to generate a docx file with page border using this tool. But I could not achieve this goal. Based on this experience, I understood that this tool did not provide a feature to put a page border on docx file pages. I found a solution for this problem. This pull request contains the solution for this mentioned problem.

var converted = htmlDocx.asBlob(content);
saveAs(converted, 'test.docx');

pageBorder additional option included in asBlob for controlling page border setup for the document:

If you want to know more,please visit the below link

http://officeopenxml.com/WPsectionBorders.php