Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Wicked PDF - Essential Rails Gems
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Jesse Wolgamott
April 10, 2013
Programming
480
4
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Wicked PDF - Essential Rails Gems
PDF Creation that Doesn't Suck
Jesse Wolgamott
April 10, 2013
Transcript
15 slides
WICKED PDF Essential Rails Gems by @jwo for @houstonrb Tuesday,
April 9, 13
PDF Creation that doesn’t suck Prawn Prince PDF Pdfkit Rtek
(latex) DocRaptor acts_as_flying_saucer Tuesday, April 9, 13
Why Wicked PDF Great API Uses HTML/CSS you’re used to
Can use javascript in your PDFs Tuesday, April 9, 13
Bad Parts Difficult to render outside of Rails Request (Though
not impossible, see codebase at end) The Binary is hard to get configured to be found Tuesday, April 9, 13
Rails 4? Does not work for CSS/JS at time of
creation :( Tuesday, April 9, 13
Install gem install wicked_pdf Tuesday, April 9, 13
Development group :development do gem "wkhtmltopdf-binary" end Tuesday, April 9,
13
Production group :production do gem 'wkhtmltopdf-heroku' end Tuesday, April 9,
13
Recommended Workflow Create the PDF monthly Save PDF to S3
in CarrierWave Send link to download file Tuesday, April 9, 13
Hints Have a report.scss that includes parts you need to
include Have a report.js that includes parts asset_sync is your friend Easiest to render partials Tuesday, April 9, 13
Saving PDFs (CarrierWave) pdf = RendersPdf .new("statement/_show", {as_of_date: Date.today} )
.render account.account_statement.store!(pdf) Tuesday, April 9, 13
Must Do’s Add “application/pdf”, :pdf to MimeTypes respond_to do |format|
format.html format.pdf do render :pdf => "file_name", layout: 'report.html', "javascript-delay" => 5000 end end Tuesday, April 9, 13
Example Tuesday, April 9, 13
What did we just see? Using Bootstrap in your PDFs
Using Morris.js to graph in your PDFs Tuesday, April 9, 13
Codebase https://github.com/jwo/railsdotpdf http://railsdotpdf.herokuapp.com/ Tuesday, April 9, 13
More Decks by Jesse Wolgamott
See All by Jesse Wolgamott
React vs React-Native
jwo
0
160
What is an API
jwo
0
240
DIY Rails Authentication
jwo
0
260
ActionCable - For Not Another Chat App
jwo
3
1.9k
SlackBot.rb - Create You a Slack Bot
jwo
1
1.5k
react-rails: an isomorphic match made in heaven
jwo
0
1.5k
Docker - next big thing
jwo
0
1.1k
Ruby 2.1 Overview
jwo
0
1.1k
Rails 4: Appetizers
jwo
1
1.1k
Other Decks in Programming
See All in Programming
3回つくってわかった、 定期実行ジョブ基盤の本質情報
takai
4
3.9k
조합이폭발하는디자인시스템이걸눈으로도테스트하라고요
giljongyu
0
750
作れるエンジニアから、価値を届けるエンジニアへ
ryunakayama
1
290
AI Augmentation Techniques with Liberty
ivargrimstad
1
470
React Native에 현대적인 빌드 도구 더하기: Rollipop 구현기
leegeunhyeok
0
180
複数ドメインを一つのアプリに統合するFlutterの設計と運用_FlutterKaigi2026登壇資料(須永高弘)
takahirosunaga
0
180
baseline으로 마이그레이션, 리팩토링 안전하게 맡기기
fornewid
1
980
Goコンパイラを作ってGoをもっと理解する / Build a Go compiler to better understand Go
ikura_hamu
0
130
Coding with AI: How to trust the storyteller (AWS Community Day Adria, Ljubljana 2026)
slobodan
0
140
當我們開始不讀 Code - AI Agent 時代,Code Review 與 Clean Code 還剩下什麼?
jame2408
1
370
TanStack Vue Query と Pinia Colada から学ぶ非同期状態の型設計
aoshi
0
670
私なりのハーネスエンジニアリング ~独自の言語処理系の開発を通して~
seosoft
0
200
Featured
See All Featured
Hiding What from Whom? A Critical Review of the History of Programming languages for Music
tomoyanonymous
3
1.4k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
The State of eCommerce SEO: How to Win in Today's Products SERPs - #SEOweek
aleyda
2
12k
How Fast Is Fast Enough? [PerfNow 2025]
tammyeverts
3
980
Mobile First: as difficult as doing things right
swwweet
225
10k
Utilizing Notion as your number one productivity tool
mfonobong
4
640
svc-hook: hooking system calls on ARM64 by binary rewriting
retrage
2
670
[RailsConf 2023] Rails as a piece of cake
palkan
59
7.1k
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4.6k
Paper Plane (Part 1)
katiecoart
PRO
3
12k
Fantastic passwords and where to find them - at NoRuKo
philnash
53
4k
The Cost Of JavaScript in 2023
addyosmani
56
10k