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
GOTOcon 2012: Taming JavaScript with Cloud9 IDE...
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
zef
May 30, 2012
Technology
1
120
GOTOcon 2012: Taming JavaScript with Cloud9 IDE: a Tale of Tree Hugging
My talk on TreeHugger.js at GOTOcon.
zef
May 30, 2012
Tweet
Share
More Decks by zef
See All by zef
Pick Your Battles
zef
1
150
GeeCON 2012: Coding in the Cloud
zef
2
340
Other Decks in Technology
See All in Technology
AIと新時代を切り拓く。これからのSREとメルカリIBISの挑戦
0gm
1
2.8k
CDK対応したAWS DevOps Agentを試そう_20260201
masakiokuda
1
350
Embedded SREの終わりを設計する 「なんとなく」から計画的な自立支援へ
sansantech
PRO
3
2.5k
外部キー制約の知っておいて欲しいこと - RDBMSを正しく使うために必要なこと / FOREIGN KEY Night
soudai
PRO
12
5.6k
生成AIを活用した音声文字起こしシステムの2つの構築パターンについて
miu_crescent
PRO
3
210
GitHub Issue Templates + Coding Agentで簡単みんなでIaC/Easy IaC for Everyone with GitHub Issue Templates + Coding Agent
aeonpeople
1
250
セキュリティについて学ぶ会 / 2026 01 25 Takamatsu WordPress Meetup
rocketmartue
1
310
All About Sansan – for New Global Engineers
sansan33
PRO
1
1.4k
30万人の同時アクセスに耐えたい!新サービスの盤石なリリースを支える負荷試験 / SRE Kaigi 2026
genda
4
1.3k
Kiro IDEのドキュメントを全部読んだので地味だけどちょっと嬉しい機能を紹介する
khmoryz
0
200
日本の85%が使う公共SaaSは、どう育ったのか
taketakekaho
1
230
プロダクト成長を支える開発基盤とスケールに伴う課題
yuu26
4
1.3k
Featured
See All Featured
The Illustrated Guide to Node.js - THAT Conference 2024
reverentgeek
0
260
The Organizational Zoo: Understanding Human Behavior Agility Through Metaphoric Constructive Conversations (based on the works of Arthur Shelley, Ph.D)
kimpetersen
PRO
0
240
The Curious Case for Waylosing
cassininazir
0
240
How to optimise 3,500 product descriptions for ecommerce in one day using ChatGPT
katarinadahlin
PRO
0
3.4k
Designing Powerful Visuals for Engaging Learning
tmiket
0
240
My Coaching Mixtape
mlcsv
0
48
Building Flexible Design Systems
yeseniaperezcruz
330
40k
Amusing Abliteration
ianozsvald
0
100
Scaling GitHub
holman
464
140k
Design in an AI World
tapps
0
140
Code Review Best Practice
trishagee
74
20k
Music & Morning Musume
bryan
47
7.1k
Transcript
Taming JavaScript with Cloud9 IDE: a Tale of Tree Hugging
Zef Hemel (@zef)
None
None
None
.js
browser.js
db.js
server.js
*.js
None
~140,000
Tooling matters
None
JavaScript Developer
None
None
None
HTML CSS JavaScript
HTML5 CSS3 JavaScript Client
HTML5 CSS3 JavaScript Client Node.js Redis Server
HTML5 CSS3 JavaScript Client Node.js Redis Server XMLHttpRequest HTML5 WebSockets
Mozilla Bespin
Mozilla Bespin Canvas
Browser Wars 2.0
DOM
Sidebar
Sidebar
Sidebar
Sidebar
Sidebar
Sidebar
Sidebar
Sidebar
JavaScript C/C++ Closure CoffeeScript Coldfusion C# CSS Groovy HTML Java
JSON LaTeX Lua Markdown OCaml Perl PHP Ruby Scad Scala SCSS SQL SVG Textile XML
None
~240,000
Component Systems Message Queues Decoupling
None
None
None
None
Tooling matters especially for JavaScript
None
Unleash the awesome power of...
tatic
program analysis
None
None
Iterating using undeclared variable
None
Warning: you are in an anonymous inner function with its
own “this” pointer
None
Did you mean “length”?
“The most important thing I have done as a programmer
in recent years is to aggressively pursue static code analysis.” John Carmack
How?
Parse Analyze
Parser Code AST
Abstract Syntax Tree a * 10 Parser Op Var Num
“*” “a” “10”
Zeon UglifyJS Narcissus Esprima language.js
performance (speed/memory) AST datastructure traversal tools
performance (speed/memory) AST datastructure traversal tools JavaScript specific
treehugger.js
“The JQuery of AST analysis.”
treehugger.js
treehugger.js Generic AST Data structure
treehugger.js Generic AST Data structure Generic Traversals
treehugger.js Generic AST Data structure Generic Traversals DSL with Pattern
Matching
treehugger.js Generic AST Data structure Generic Traversals DSL with Pattern
Matching Language- Specific Parsers
treehugger.js Generic AST Data structure Generic Traversals DSL with Pattern
Matching Language- Specific Parsers JavaScript (UglifyJS-based)
treehugger.js Generic AST Data structure Generic Traversals DSL with Pattern
Matching Language- Specific Parsers JavaScript (UglifyJS-based)
a * 10 Op Var Num “*” “a” “10”
Op("*", Var("a"), Num("10")) Op Var Num “*” “a” “10”
Op("*", Var("a"), Num("10")) ATerm Op Var Num “*” “a” “10”
Constructors Lists Strings Var(_) [_, _] "hello" Placeholders x
let’s play
What can you do with it?
Low-level tooling
None
Intelligent code completion
Complex refactoring
Cloud
Big data
What if...
Project 1 Project 2 Project 3 Project 4 Project 5
Project 6
Your (dev) environment matters use static analysis tools
http://c9.io @zef http://github.com/ajaxorg/treehugger