1 / 11

Google Closure Tools

Michael Robertson Yuta Takayama. Google Closure Tools. * Google Closure Tools are open source versions of tools used in many of Google's sites and web applications. * These tools include: * JavaScript optimizer (Closure Compiler) * Comprehensive JavaScript library (Closure Library)

pisces
Download Presentation

Google Closure Tools

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Michael Robertson Yuta Takayama Google Closure Tools

  2. * Google Closure Tools are open source versions of tools used in many of Google's sites and web applications. * These tools include: * JavaScript optimizer (Closure Compiler) * Comprehensive JavaScript library (Closure Library) * Templating system for Java and JavaScript (Closure Templates) * JavaScript style checker/fixer (Closure Linter) * Enhanced stylesheet language (Closure Stylesheets) * Can each be used individually or altogether

  3. Closure Compiler * Compiles JavaScript into compact and high-performance code * Checks syntax, variable references, and types plus warns against common problems * Removes dead code and rewrites and minimizes the rest * Reduces the size of the JavaScript files by making them more efficient leading to faster loads and less bandwidth needs

  4. Closure Compiler * Works only on files that contain only JavaScript (not embedded in HTML) * Can use closure compiler with other JavaScript minifiers * Available for all platforms that run Java (compiler is written in Java)

  5. Closure Library * Cross-browser and server-agnostic JavaScript library * Large number of reusable UI widgets and controls * Base JavaScript library for many Google products such as: * Gmail * Maps * Docs * Google+ * and more...

  6. Closure Templates * Client- and server-side templating system to build reusable HTML and UI elements * Simple syntax and customizable * Small components that can be composed to form the UI * Implemented for both Java and JavaScript * Works well in any web application environment to be used with any other libraries, frameworks, or other tools * Used in Gmail and Google Docs

  7. * Secure - Closure Templates are contextually auto-escaped to reduce the risk of XSS * XSS - “Cross-site scripting” * Type of insecurity vulnerability that enables attackers to inject client-side script into Web pages viewed by other users Closure Templates

  8. Closure Linter * Utility that checks JavaScript files for style issues such as operator placement, missing semicolons, spacing, the presence of JsDoc annotations, and more * Used on Gmail, Google Docs, and other Google products * Enforces the guidelines set in the Google JavaScript Style Guide * Can automatically fix common errors

  9. Closure Linter

  10. Closure Stylesheets * Supports a number Google extensions to the standard CSS language → Can define and use variables, functions, conditionals, and mixins in your stylesheet * Stylesheets are more readable and maintainable * An included tool can compile the stylesheet down into standard CSS and supports minification, linting, directionality (right-to-left flipping), and class renaming

  11. https://developers.google.com/closure/ For More Information

More Related