Class: BreezyPDF::HTML2PDF

Inherits:
Object
  • Object
show all
Defined in:
lib/breezy_pdf/html_2_pdf.rb

Overview

Transform an HTML slug to a PDF Access it’s URL or download it locally and access it as a Tempfile

Instance Method Summary collapse

Constructor Details

#initialize(asset_host, html_string, metadata = {}) ⇒ HTML2PDF

Returns a new instance of HTML2PDF.



7
8
9
10
11
# File 'lib/breezy_pdf/html_2_pdf.rb', line 7

def initialize(asset_host, html_string,  = {})
  @asset_host  = asset_host
  @html_string = html_string
      = 
end

Instance Method Details

#to_fileObject



17
18
19
# File 'lib/breezy_pdf/html_2_pdf.rb', line 17

def to_file
  file
end

#to_urlObject



13
14
15
# File 'lib/breezy_pdf/html_2_pdf.rb', line 13

def to_url
  url
end