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
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Ross Kaffenberger
January 16, 2019
Programming
1.5k
2
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
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
More Decks by Ross Kaffenberger
See All by Ross Kaffenberger
A Webpack Survival Guide for Rails Developers
rossta
1
2.8k
What I look for in a Junior Developer
rossta
2
1.1k
Progressive Web Apps on Rails
rossta
0
2.4k
Enumerable's Ugly Cousin - GORUCO Microtalk
rossta
0
470
Enumerator - Enumerable's Ugly Cousin
rossta
1
590
Recurring Events with Montrose
rossta
3
2.1k
Enumerable - How I Fell in Love with Ruby
rossta
20
4.9k
Create and Deploy an Ember App in 5 Minutes
rossta
7
3.8k
Other Decks in Programming
See All in Programming
1年で人数1.5倍、PR数5.5倍増。 品質とアウトカムはどうなったか、 何が効いたか
ike002jp
0
140
20260623_Loop Engineeringで自分の分身の問い合わせBotを作る
ryugen04
0
220
JAWS-UG横浜 #102 AWSサ終供養LT会 成仏できない AWS サービスたち 〜本日、三体供養します〜
maroon1st
0
210
壊れたパーサから始める関数型設計と構成的なパーサ #fp_matsuri
raiga0310
2
320
Generative UI & AI-Assistants for Your Angular Solutions
manfredsteyer
PRO
1
190
任せる範囲はこう広がった / How the Scope of AI Delegation Has Expanded
nrslib
1
260
Laravel Boostに学ぶ、AIにPHPを書かせる技術 〜OSSの実装から蒸留するエージェント制御の王道〜
kentaroutakeda
3
460
AI がコードを書く時代における新卒エンジニアの仕事風景 (2026) / New Graduate Engineers in the Era of AI Coding (2026)
sushichan044
0
220
ローカルLLMでどこまでコードが書けるか -縮小版 / How much code can be written on a local LLM Shortened
kishida
2
190
Hatena Engineer Seminar #37「言語モデルの活用に関する研究」
slashnephy
0
520
どこまでゆるくて許されるのか
tk3fftk
0
500
5分で問診!Composer セキュリティ健康診断
codmoninc
0
340
Featured
See All Featured
The SEO Collaboration Effect
kristinabergwall1
1
510
WENDY [Excerpt]
tessaabrams
11
38k
Optimising Largest Contentful Paint
csswizardry
37
3.8k
How Software Deployment tools have changed in the past 20 years
geshan
0
34k
The untapped power of vector embeddings
frankvandijk
2
1.8k
Accessibility Awareness
sabderemane
1
160
The Illustrated Guide to Node.js - THAT Conference 2024
reverentgeek
1
410
A designer walks into a library…
pauljervisheath
211
24k
Principles of Awesome APIs and How to Build Them.
keavy
128
18k
From π to Pie charts
rasagy
0
240
The Impact of AI in SEO - AI Overviews June 2024 Edition
aleyda
5
1.1k
SEO for Brand Visibility & Recognition
aleyda
0
4.6k
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]