Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Wicked PDF - Essential Rails Gems
Search
Jesse Wolgamott
April 10, 2013
Programming
4
470
Wicked PDF - Essential Rails Gems
PDF Creation that Doesn't Suck
Jesse Wolgamott
April 10, 2013
Tweet
Share
More Decks by Jesse Wolgamott
See All by Jesse Wolgamott
React vs React-Native
jwo
0
140
What is an API
jwo
0
200
DIY Rails Authentication
jwo
0
220
ActionCable - For Not Another Chat App
jwo
3
1.8k
SlackBot.rb - Create You a Slack Bot
jwo
1
1.4k
react-rails: an isomorphic match made in heaven
jwo
0
1.4k
Docker - next big thing
jwo
0
980
Ruby 2.1 Overview
jwo
0
1k
Rails 4: Appetizers
jwo
1
1k
Other Decks in Programming
See All in Programming
React 19でつくる「気持ちいいUI」- 楽観的UIのすすめ
himorishige
11
5.7k
[KNOTS 2026登壇資料]AIで拡張‧交差する プロダクト開発のプロセス および携わるメンバーの役割
hisatake
0
120
AtCoder Conference 2025
shindannin
0
990
責任感のあるCloudWatchアラームを設計しよう
akihisaikeda
3
120
実は歴史的なアップデートだと思う AWS Interconnect - multicloud
maroon1st
0
350
IFSによる形状設計/デモシーンの魅力 @ 慶應大学SFC
gam0022
1
260
なるべく楽してバックエンドに型をつけたい!(楽とは言ってない)
hibiki_cube
0
130
Data-Centric Kaggle
isax1015
2
700
[AI Engineering Summit Tokyo 2025] LLMは計画業務のゲームチェンジャーか? 最適化業務における活⽤の可能性と限界
terryu16
2
440
公共交通オープンデータ × モバイルUX 複雑な運行情報を 『直感』に変換する技術
tinykitten
PRO
0
200
MDN Web Docs に日本語翻訳でコントリビュート
ohmori_yusuke
0
600
高速開発のためのコード整理術
sutetotanuki
1
330
Featured
See All Featured
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
9
1.1k
Six Lessons from altMBA
skipperchong
29
4.1k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
122
21k
Docker and Python
trallard
47
3.7k
A Soul's Torment
seathinner
5
2.2k
4 Signs Your Business is Dying
shpigford
187
22k
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
45
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
333
22k
Unsuck your backbone
ammeep
671
58k
How GitHub (no longer) Works
holman
316
140k
Impact Scores and Hybrid Strategies: The future of link building
tamaranovitovic
0
190
Building a A Zero-Code AI SEO Workflow
portentint
PRO
0
260
Transcript
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