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.5k
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.7k
What I look for in a Junior Developer
rossta
2
1.1k
Progressive Web Apps on Rails
rossta
0
2.3k
Enumerable's Ugly Cousin - GORUCO Microtalk
rossta
0
420
Enumerator - Enumerable's Ugly Cousin
rossta
1
550
Recurring Events with Montrose
rossta
3
2.1k
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
フロントエンド開発の勘所 -複数事業を経験して見えた判断軸の違い-
heimusu
7
2.8k
CSC307 Lecture 04
javiergs
PRO
0
660
「ブロックテーマでは再現できない」は本当か?
inc2734
0
1k
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
600
そのAIレビュー、レビューしてますか? / Are you reviewing those AI reviews?
rkaga
6
4.6k
Amazon Bedrockを活用したRAGの品質管理パイプライン構築
tosuri13
5
760
AIによるイベントストーミング図からのコード生成 / AI-powered code generation from Event Storming diagrams
nrslib
2
1.9k
Lambda のコードストレージ容量に気をつけましょう
tattwan718
0
140
Raku Raku Notion 20260128
hareyakayuruyaka
0
340
Architectural Extensions
denyspoltorak
0
290
AIフル活用時代だからこそ学んでおきたい働き方の心得
shinoyu
0
140
CSC307 Lecture 01
javiergs
PRO
0
690
Featured
See All Featured
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
359
30k
What’s in a name? Adding method to the madness
productmarketing
PRO
24
3.9k
Dominate Local Search Results - an insider guide to GBP, reviews, and Local SEO
greggifford
PRO
0
78
The agentic SEO stack - context over prompts
schlessera
0
640
Amusing Abliteration
ianozsvald
0
100
Embracing the Ebb and Flow
colly
88
5k
Pawsitive SEO: Lessons from My Dog (and Many Mistakes) on Thriving as a Consultant in the Age of AI
davidcarrasco
0
67
Introduction to Domain-Driven Design and Collaborative software design
baasie
1
590
How To Stay Up To Date on Web Technology
chriscoyier
791
250k
Technical Leadership for Architectural Decision Making
baasie
2
250
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
0
77
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
162
16k
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]