Skip to content

Palmabit-IT/htmlToPdfMake

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HtmlToPdfMake

Convert html to PdfMake schema

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Installing

npm i -S @palmabit/htmltopdfmake

Usage

const { pdfForElement } = require('@palmabit/htmltopdfmake')
const result = pdfForElement('<div><h1>header1</h1></div>')

//result
[
  { "stack": [
    { "text": [] },
    { "stack": [
      { "text": [
        { "text": "header1", "fontSize": 32, "bold": true }
        ]
      }]
    }
  ]
]

Built With

  • Parse5 - HTML parsing/serialization toolset for Node.js. WHATWG HTML Living Standard (aka HTML5)-compliant.

Versioning

We use SemVer for versioning. For the versions available, see the tags on this repository.

License

This project is licensed under the MIT License - see the LICENSE.md file for details

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published