72

GitHub - Mindinventory/Golang-HTMLTOPDF-Converter: Golang HTMLTOPDF Converter

 5 years ago
source link: https://github.com/Mindinventory/Golang-HTMLTOPDF-Converter
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

README.MD

Golang HTML to PDF Converter

Follow below steps to generate HTML to PDF using Golang:

  1. Create a sample HTML file inside of your project.

  2. Download go package using the below command for parsing the HTMl template. go get "github.com/SebastiaanKlippert/go-wkhtmltopdf

  3. We need to download another package for converting this html parse data to pdf using the below command.

    go get "html/template"

  4. Make sure to download the below library in your system using the following command.
    sudo apt install wkhtmltopdf

After finish above steps, You can generate pdf file from html.

NOTES: Don't forget to mention your html and pdf path details inside your code.

LICENSE!

CoverFlow is MIT-licensed

Let us know!

We’d be really happy if you sent us links to your projects where you use our component. Just send an email to [email protected] And do let us know if you have any questions or suggestion regarding our work.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK