1.1.0 ā€¢ Published 4 years ago

node-html-to-image-cli v1.1.0

Weekly downloads
37
License
Apache-2.0
Repository
github
Last release
4 years ago

A cli based on node-html-to-image that generates images from HTML

šŸ  Homepage

Description

This is cli is based on node-html-to-image. It generates an image from an HTML file. node-html-to-image provides more options and lets you pass down custom configuration to puppeteer which is used under the hood.

node-html-to-image-cli's demo

Prerequisites

  • node >=10

Install

This step is uneccessary if you use npx.

yarn add global node-html-to-image-cli
# or
npm install -g node-html-to-image-cli

Usage

Without handlebars template

npx node-html-to-image-cli examples/simple.html ./image.png

With additional data passed to the template

npx node-html-to-image-cli examples/handlebars.html ./image.png --content ./examples/handlebars.json

Arguments

ArgumentDescription
htmlpath to a html file
outputpath where image should be created

Options

OptionAliasDescription
--type-ttype of image that should be generated
--transparentnonedetermine if background of the generated image should be transparent
--content-cpath to a content file with handlebars template

Related

Author

šŸ‘¤ FRIN Yvonnick frin.yvonnick@gmail.com

šŸ¤ Contributing

Contributions, issues and feature requests are welcome!Feel free to check issues page.

Show your support

Give a ā­ļø if this project helped you!

šŸ“ License

Copyright Ā© 2019 FRIN Yvonnick <frin.yvonnick@gmail.com>. This project is Apache--2.0 licensed.


This README was generated with ā¤ļø by readme-md-generator