How to export a page to PDF with JS

I am writing a chrome plug-in, and there is a need to use JS to export the current page to PDF and save it locally. The export PDF style is required to be retained, with optional text and clickable links, which is actually the same as the PDF function exported using the chrome print function, but I need to use the code to automatically complete this function. Ask God for advice on how to do it


jsPDF or html2canvas

https://github.com/linwalker/.

  • How to export a page to PDF with JS

    I am writing a chrome plug-in, and there is a need to use JS to export the current page to PDF and save it locally. The export PDF style is required to be retained, with optional text and clickable links, which is actually the same as the PDF function ex...

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e46cd0-2711f.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e46cd0-2711f.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?