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
Using Source Maps in 2015
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Matt Steele
April 08, 2015
Programming
990
0
Share
Using Source Maps in 2015
And introducing the greatest compiles-to-js language of all time, arnoldc.js
Matt Steele
April 08, 2015
More Decks by Matt Steele
See All by Matt Steele
Upgrading to Angular 2 using ngUpgrade
mattdsteele
0
1.1k
Reactive Programming with RxJS
mattdsteele
0
120
GET TO THE CHOPVAR
mattdsteele
0
190
Responsive Images using <picture> and srcset/sizes
mattdsteele
1
1.4k
The Decorator Pattern
mattdsteele
0
83
Diving Into the Device API
mattdsteele
1
840
Unit Testing JavaScript when you're Afraid of JavaScript
mattdsteele
3
780
What Zelda Taught Me about Front End Engineering
mattdsteele
5
1.1k
Other Decks in Programming
See All in Programming
PDI: Como Alavancar Sua Carreira e Seu Negócio
marcelgsantos
0
110
Strategy for Finding a Problem for OSS: With Real Examples
kibitan
0
140
Linux Kernelの1文字のミスで 権限昇格ができた話
rqda
0
2.3k
Going Multiplatform with Your Android App (Android Makers 2026)
zsmb
2
350
PCOVから学ぶコードカバレッジ #phpcon_odawara
o0h
PRO
0
230
Codex CLI でつくる、Issue から merge までの開発フロー
amata1219
0
330
10年分の技術的負債、完済へ ― Claude Code主導のAI駆動開発でスポーツブルを丸ごとリプレイスした話
takuya_houshima
0
1.8k
条件判定に名前、つけてますか? #phperkaigi #c
77web
2
980
ドメインイベントでビジネスロジックを解きほぐす #phpcon_odawara
kajitack
2
120
まかせられるPM・まかせられないPM / DevTech GUILD Meetup
yusukemukoyama
0
110
仕様漏れ実装漏れをなくすトレーサビリティAI基盤のご紹介
orgachem
PRO
8
5k
へんな働き方
yusukebe
6
2.9k
Featured
See All Featured
Java REST API Framework Comparison - PWX 2021
mraible
34
9.2k
Producing Creativity
orderedlist
PRO
348
40k
世界の人気アプリ100個を分析して見えたペイウォール設計の心得
akihiro_kokubo
PRO
68
38k
The Language of Interfaces
destraynor
162
26k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
128
55k
Exploring the relationship between traditional SERPs and Gen AI search
raygrieselhuber
PRO
2
3.8k
Building Applications with DynamoDB
mza
96
7k
Have SEOs Ruined the Internet? - User Awareness of SEO in 2025
akashhashmi
0
310
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
12
1.6k
エンジニアに許された特別な時間の終わり
watany
106
240k
How to Ace a Technical Interview
jacobian
281
24k
The Cost Of JavaScript in 2023
addyosmani
55
9.8k
Transcript
SOURCE MAPS
IT’S SHOWTIME
It’s 2015 Tools Are Complicated
Compilers
Compilers
Compilers
Compilers
Compilers
Transpilers
Transpilers
Transpilers
None
Preprocessors
Preprocessors
Preprocessors
Preprocessors
Postprocessors
Postprocessors
Postprocessors
Postprocessors
Postprocessors
I’LL BE BACK
Build Phase
Build Phase
Build Phase
Build Phase
Now you have two problems
None
DEBUG THIS
Source Maps To The Rescue
Content Source
CSS & JavaScript
app.js app.min.js Without Source Maps
app.js app.min.js app.min.js.map With Source Maps
None
None
None
None
Variable Length Quantity http://www.html5rocks.com/en/tutorials/developertools/sourcemaps/
It all Just Works
Demo
Multi-Level Source Maps
HASTA LA VISTA, BABY
ES6 CoffeeScript TypeScript
ES6 CoffeeScript TypeScript Concat
ES6 CoffeeScript TypeScript Concat Minify
Demo
ArnoldC
None
IT'S SHOWTIME TALK TO THE HAND "hello world" YOU HAVE
BEEN TERMINATED Hello World
GET TO THE CHOPPER a HERE IS MY INVITATION 4
GET UP b YOU'RE FIRED 2 ENOUGH TALK a = (4 + b) * 2
HEY CHRISTMAS TREE foo YOU SET US UP @I LIED
HEY CHRISTMAS TREE bar YOU SET US UP @NO PROBLEMO foo = false bar = true
Two Problems
1.
✓
✓ ✗ ✗
✓ … ✗ ✗
None
None
None
None
None
2.
2.
So
I wrote a compiler
arnoldc.js https://github.com/mattdsteele/arnoldc.js
Compiles from ArnoldC to JavaScript
Compiles from ArnoldC to JavaScript (With Source Maps)
DO IT NOW
11+ Source Maps
1. Upgrade your tools Tips
2. Gulp > Grunt (for this) Tips gulp.task('javascript', function() {
gulp.src('src/**/*.js') .pipe(sourcemaps.init()) .pipe(plugin1()) .pipe(plugin2()) .pipe(sourcemaps.write()) .pipe(gulp.dest('dist')); });
3. Inline your sourcesContent Tips
Tips 4. Source Map Visualization Tool http://sokra.github.io/source-map-visualization/
@mattdsteele http://steele.blue