New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add ClosureCompiler
filter.
#170
Conversation
*/ | ||
protected $_settings = array( | ||
'level' => null, | ||
'print' => "%s:\n%s\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this need to be configurable?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No.
Bumping this to see if there are any chances this will get merged soon so I can use the original repo again? |
|
||
$$setting = $this->_query($content, $args); | ||
printf("%s:\n%s\n", ucfirst($setting), $$setting); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this printing here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the shell command's output. Should I remove it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not overly familiar with the closure webservice, what purpose does printing this out serve?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Closure can return an output:
output_info
The value of this parameter indicates the kind of information that you want from the compiler.
There are four possible kinds of output: compiled_code, warnings, errors, and statistics. This
example uses the value compiled_code, which tells the Closure Compiler service to output the
compressed version of the JavaScript it receives in the request.
In here it's used to output 'warnings' and/or 'statistics'.
Add `ClosureCompiler` filter.
A new filter for those of us who want to use the Google Closure compiler API. Similar to the ClosureJS filter but without having to install JAVA nor the
closure/compiler.jar
.The compilation level can be set using the
level
key in settings like so:One can also check statistics and/or warnings (only in debug mode):
Furthermore, extra parameters can be passed to the API like so:
That's about it!
Hoping it is judged useful to others and gets added to the plugin's core.
Best,
Jad