mirror of
https://github.com/lloeki/tilt-pdf.git
synced 2025-12-06 10:34:41 +01:00
remove hardcoded defaults
This commit is contained in:
parent
6a9fa9bbf3
commit
b5dafd730b
1 changed files with 0 additions and 19 deletions
|
|
@ -2,25 +2,6 @@ require 'pdfkit'
|
||||||
require 'tilt'
|
require 'tilt'
|
||||||
require 'tilt/template'
|
require 'tilt/template'
|
||||||
|
|
||||||
PDFKit.configure do |config|
|
|
||||||
config.wkhtmltopdf =
|
|
||||||
'/Applications/wkhtmltopdf.app/Contents/MacOS/wkhtmltopdf'
|
|
||||||
config.default_options = {
|
|
||||||
page_size: 'A4',
|
|
||||||
orientation: 'portrait',
|
|
||||||
print_media_type: true,
|
|
||||||
dpi: 600,
|
|
||||||
margin_top: 0,
|
|
||||||
margin_bottom: 0,
|
|
||||||
margin_left: 0,
|
|
||||||
margin_right: 0,
|
|
||||||
header_spacing: 0,
|
|
||||||
footer_spacing: 0,
|
|
||||||
disable_smart_shrinking: true,
|
|
||||||
zoom: 1.0,
|
|
||||||
}
|
|
||||||
end
|
|
||||||
|
|
||||||
module Tilt
|
module Tilt
|
||||||
class PDFTemplate < Template
|
class PDFTemplate < Template
|
||||||
self.default_mime_type = 'application/pdf'
|
self.default_mime_type = 'application/pdf'
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue