HtmlToImage
Elixir wrapper around wkhtmltoimage tool for converting HTML into images
Installation
-
Add
html_to_imageto your list of dependencies inmix.exs:
def deps do
[{:html_to_image, "~> 0.1.0"}]
end-
Ensure
html_to_imageis started before your application:
def application do
[applications: [:html_to_image]]
endUsage
template = "<html><p>Hello, <b>HtmlToImage</b>!</p></html>"
{ :ok, data } = HtmlToImage.convert(template)Complete API reference is available at hexdocs