Launch Week Day 1: Socket for Jira Is Now Available.Learn More
Socket
Book a DemoSign in
Socket

falcon-invoice

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

falcon-invoice

Generate PDF invoices using html templates and mustaches!

latest
Source
npmnpm
Version
0.0.4
Version published
Weekly downloads
1
-75%
Maintainers
1
Weekly downloads
 
Created
Source

falcon-invoice

Generate PDF invoices using HTML templates and mustaches!

Installation

npm install falcon-invoice

Usage

Check out test/index.js for a more detailed example!

const invoice = require('falcon-invoice')

const template = '/path/to/template'
const templateVariables = {
  name: 'Herp Derpington'
}

// Optional options
const options = {
  filename: 'differentName.pdf',
  pdfOptions: {
    orientation: 'landscape'
  }
}

invoice(template, templateVariables, options)

Template Example

<!doctype html>
<html>
  <head>
    <meta charset="utf-8">
  </head>
  <body>
    <p>
      Customer Name: {{name}}
    </p>
  </body>
</html>

Output example

alt text

Credits

This package uses: html-pdf and mustache

I got my test html template from: https://github.com/NextStepWebs/simple-html-invoice-template

Keywords

invoice

FAQs

Package last updated on 20 Jul 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts