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
Getting Lazy with Vue and PDFs
Search
Ross Kaffenberger
January 16, 2019
Programming
2
1.4k
Getting Lazy with Vue and PDFs
I share the most important lessons learned while building a PDF Viewer in Vue.
Ross Kaffenberger
January 16, 2019
Tweet
Share
More Decks by Ross Kaffenberger
See All by Ross Kaffenberger
A Webpack Survival Guide for Rails Developers
rossta
1
2.5k
What I look for in a Junior Developer
rossta
2
1k
Progressive Web Apps on Rails
rossta
0
2.3k
Enumerable's Ugly Cousin - GORUCO Microtalk
rossta
0
390
Enumerator - Enumerable's Ugly Cousin
rossta
1
530
Recurring Events with Montrose
rossta
3
2k
Enumerable - How I Fell in Love with Ruby
rossta
20
4.7k
Create and Deploy an Ember App in 5 Minutes
rossta
7
3.7k
Other Decks in Programming
See All in Programming
理論と実務のギャップを超える
eycjur
0
120
複雑化したリポジトリをなんとかした話 pipenvからuvによるモノレポ構成への移行
satoshi256kbyte
1
1k
Go Conference 2025: Goで体感するMultipath TCP ― Go 1.24 時代の MPTCP Listener を理解する
takehaya
8
1.6k
止められない医療アプリ、そっと Swift 6 へ
medley
1
150
その面倒な作業、「Dart」にやらせませんか? Flutter開発者のための業務効率化
yordgenome03
1
110
技術的負債の正体を知って向き合う / Facing Technical Debt
irof
0
150
チームの境界をブチ抜いていけ
tokai235
0
160
Writing Better Go: Lessons from 10 Code Reviews
konradreiche
0
200
バッチ処理を「状態の記録」から「事実の記録」へ
panda728
PRO
0
140
CSC509 Lecture 03
javiergs
PRO
0
330
デミカツ切り抜きで面倒くさいことはPythonにやらせよう
aokswork3
0
220
All About Angular's New Signal Forms
manfredsteyer
PRO
0
110
Featured
See All Featured
Typedesign – Prime Four
hannesfritz
42
2.8k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
32
2.3k
Raft: Consensus for Rubyists
vanstee
139
7.1k
Building a Modern Day E-commerce SEO Strategy
aleyda
43
7.7k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
52
5.6k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
333
22k
How to Ace a Technical Interview
jacobian
280
24k
Large-scale JavaScript Application Architecture
addyosmani
514
110k
StorybookのUI Testing Handbookを読んだ
zakiyama
31
6.2k
Become a Pro
speakerdeck
PRO
29
5.5k
A Tale of Four Properties
chriscoyier
160
23k
Balancing Empowerment & Direction
lara
4
680
Transcript
Ross Kaffenberger @rossta Getting Lazy with Vue and PDFs
Ross Kaffenberger @rossta Building a PDF Vue-er
#dadjokes
None
• ross kaffenberger @rossta
rossta.net/vue-pdfjs-demo
None
PDF.js fetching
None
PDF.js rendering
None
PDF.js in Vue
None
None
Problem: Large PDFs
•Lazy render: draw to canvas when visible •“Infinite” scroll: fetch
pages in batches
Iteration #1: Math!
None
None
None
None
None
None
None
None
Problem: Vue cannot watch $el properties
Manual work
None
None
None
None
Next iteration:
IntersectionObserver!
None
None
Advantages
•no $el property tracking •less code, fewer bugs •easier to
extend
Akryum/vue-observe-visibility
Lesson: Opt for Vue-friendliness
None
Lesson: Be curious and flexible
rossta/vue-pdfjs-demo
@rossta rossta.net/talks
[email protected]