Taming Javascript with Cloud9 IDE: a Tale of Tree Hugging

Taming Javascript with Cloud9 IDE: a Tale of Tree Hugging

Taming JavaScript with Cloud9 IDE: a Tale of Tree Hugging Zef Hemel (@zef) .js browser.js db.js server.js *.js ~140,000 Tooling matters JavaScript Developer HTML CSS JavaScript HTML5 Client CSS3 JavaScript HTML5 Client CSS3 JavaScript Node.js Server Redis HTML5 Client CSS3 JavaScript XMLHttpRequest HTML5 WebSockets Node.js Server Redis Sidebar Sidebar Sidebar Sidebar Sidebar Sidebar Sidebar Sidebar ~240,000 Component Systems Decoupling Message Queues Tooling matters especially for JavaScript Unleash the awesome power of... tatic program analysis Iterating using undeclared variable Warning: you are in an anonymous inner function with its own “this” pointer 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 Code Parser AST Abstract Syntax Tree Op a * 10 Parser “*” Var Num “a” “10” Zeon Narcissus UglifyJS language.js Esprima 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 Generic AST Data structure treehugger.js Generic AST Data structure treehugger.js Generic Traversals Generic AST Data structure DSL with Pattern Matching treehugger.js Generic Traversals Generic AST Data structure DSL with Language- Pattern Specific Parsers Matching treehugger.js Generic Traversals Generic AST Data structure DSL with Language- Pattern Specific Parsers Matching treehugger.js JavaScript (UglifyJS-based) Generic Traversals Generic AST Data structure DSL with Language- Pattern Specific Parsers Matching treehugger.js JavaScript (UglifyJS-based) Generic Traversals Op a * 10 “*” Var Num “a” “10” Op Op("*", Var("a"), “*” Var Num Num("10")) “a” “10” Op ATerm Op("*", Var("a"), “*” Var Num Num("10")) “a” “10” Constructors Var(_) Lists [_, _] Strings "hello" Placeholders x let’s play What can you do with it? Low-level tooling Intelligent code completion Complex refactoring Cloud Big data What if... Project 4 Project 5 Project 1 Project 3 Project 2 Project 6 Your (dev) environment matters use static analysis tools @zef http://github.com/ajaxorg/treehugger http://c9.io.

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    80 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us