Questions tagged [google-closure]

Google Closure is a framework for writing large-scale applications in JavaScript. It includes an extensive library, a linter, a compiler, a template system, and a stylesheet language.

Google Closure is a framework for writing large-scale applications in JavaScript. It includes an extensive library, a linter, a compiler, a template system, and a stylesheet language.

Closure is an Object-Oriented framework which borrows many concepts from Java, such as support for strong typing for compile-time checking, and deep object inheritance hierarchies.

528 questions
191
votes
8 answers

What does Google Closure Library offer over jQuery?

Considering business background community support available extensions default set of features simplicity of use and reliability why do you prefer one over the another?
pestaa
  • 4,723
  • 2
  • 20
  • 32
115
votes
5 answers

How to document a string type in jsdoc with limited possible values

I am having a function that accepts one string parameter. This parameter can have only one of a few defined possible values. What is the best way to document the same? Should shapeType be defined as enum or TypeDef or something…
63
votes
4 answers

difference between "void 0 " and "undefined"

I'm using "Closure Compiler", when compiling my scripts I spend the following: Before compiling: // ==ClosureCompiler== // @compilation_level SIMPLE_OPTIMIZATIONS // @output_file_name default.js // @formatting pretty_print,print_input_delimiter //…
andres descalzo
  • 14,451
  • 12
  • 60
  • 105
57
votes
6 answers

TinyMCE Paths, How to specify where to load things like editor_plugin.js

I installed TinyMCE, everything was working great. I then used Google Closure to package my site's JavaScript along with TinyMCE_src The problem I'm having is that TinyMCE is now making calls…
AnApprentice
  • 97,752
  • 174
  • 583
  • 971
52
votes
7 answers

Should I use the YUI Compressor or the new Google Closure compiler to compress my JavaScript?

YUI Compressor was the consensus best tool for minimizing, but Closure seems like it could be better.
45
votes
2 answers

Google Closure minifier online?

Has anyone setup an online copy/paste utility for Google's Closure minifier? I'm working on a project and I want to minify part of the code manually without having to setup the entire project on my own.
Geuis
  • 37,442
  • 53
  • 145
  • 213
44
votes
2 answers

How does Angular JS relate to Google Closure?

Now that AngularJS 1.0 is released I am wondering how this project fits together with the other general-purpose JavaScript framework / tool from Google, Closure. I have only seen basic description of those two technologies (and read about a half of…
Borek Bernard
  • 43,410
  • 50
  • 148
  • 224
39
votes
10 answers

jQuery compiled with Google Closure Compiler

Has anyone compiled jQuery against Google's newly-released Closure compiler? There has been reported huge savings in code size. I'm curious what the benefit is if jQuery was compiled with it.
Ted
  • 555
  • 2
  • 5
  • 5
38
votes
8 answers

Google Closure Compiler with jQuery applications

I have a lot of time invested in jquery and a large application built with it. Recently I've been reviewing Google Closure Library, but at this time have found it to be not nearly as elegant as jquery. I believe it may have some potential and will…
Tauren
  • 25,387
  • 37
  • 126
  • 165
32
votes
5 answers

How to force google closure compiler to keep "use strict"; in the compiled js code?

If you're using the module pattern and have something like this: (function () { "use strict"; // this function is strict... }()); and compile the code using the Google Closure Compiler, the "use strict"; directive will not make it into the…
ivo
  • 3,891
  • 5
  • 30
  • 41
30
votes
5 answers

Is there a way to generate Javascript API documentation like the Google Closure Library API Documentation?

I'm trying to find a tool that generates HTML documentation for my Javascript source code. Does anyone know if the tool that Google uses to generate the interface at the following URLs is open source? Would I be able to generate similar output?…
28
votes
1 answer

Accessing "this" in Clojurescript

Is there a way to access the "this" object in clojurescript? I am having issues with event propagation when I wrap an icon with an anchor and try to attach a handlder to the anchor. Without access to "this" in the handler I am constantly dealing…
Jon Rose
  • 1,379
  • 1
  • 13
  • 24
25
votes
1 answer

Why does Google's Closure Compiler leave a few unnecessary spaces or line breaks?

I've noticed that every time I use Google's Closure Compiler Service, it leaves a few unnecessary spaces in the compiled code presented on the right-hand side of the page. These correspond to line breaks in the hosted version of the compiled…
Bungle
  • 17,944
  • 23
  • 75
  • 101
22
votes
4 answers
19
votes
3 answers

How to merge .CSS files with Sass (or other tool)?

I can use Sass to compile multiple .SCSS or .SASS input files into a single .CSS output file using @import as described here. If I use @import to include normal .CSS files, they are not merged. The output .CSS file still contains the @import…
jwfearn
  • 26,394
  • 26
  • 89
  • 117
1
2 3
35 36