Re: [closure-compiler-discuss] ClosureCompiler.js - Closure Compiler for node.js

991 views
Skip to first unread message

John Lenz

unread,
Mar 7, 2013, 11:12:58 AM3/7/13
to closure-compiler

Nifty. I wonder where a good place to record this would be?

On Mar 7, 2013 7:38 AM, "Daniel Wirtz" <dc...@dcode.io> wrote:
The all-round carefree package. Includes Closure Compiler and a JRE built from OpenJDK. Zero dependencies, no environment variables to set, works out of the box.

GitHub: https://github.com/dcodeIO/ClosureCompiler.js
npm: https://npmjs.org/package/closurecompiler

I am thankful for any feedback from experienced CC users. Hope you'll find it useful!

--
 
---
You received this message because you are subscribed to the Google Groups "Closure Compiler Discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to closure-compiler-d...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Alan Leung

unread,
Mar 7, 2013, 2:16:58 PM3/7/13
to closure-comp...@googlegroups.com

John Lenz

unread,
Mar 7, 2013, 6:31:12 PM3/7/13
to closure-compiler
Right. Done.

Daniel Wirtz

unread,
Mar 8, 2013, 12:53:48 PM3/8/13
to closure-comp...@googlegroups.com
Cool!

I also finished inclusion of "node.js Closure Compiler Externs" (see the other thread) into ClosureCompiler.js. Specifying "--externs=node" now includes all node.js specific externs and makes compiling for node.js a breeze.

John Lenz

unread,
Mar 9, 2013, 3:12:10 PM3/9/13
to closure-compiler

Thanks for sharing your work!

On Mar 8, 2013 9:53 AM, "Daniel Wirtz" <dc...@dcode.io> wrote:
Cool!

I also finished inclusion of "node.js Closure Compiler Externs" (see the other thread) into ClosureCompiler.js. Specifying "--externs=node" now includes all node.js specific externs and makes compiling for node.js a breeze.

--

greg...@gmail.com

unread,
Dec 16, 2013, 11:20:45 PM12/16/13
to closure-comp...@googlegroups.com
I am trying (desperately) to figure out how to output multiple min.js files (1 per file in a directory), as it is, closure is always creating one bundled file and I don't want that. Do you know of a way to do that? I searched Stack Overflow and found an article that describes using modules, but I don't quite follow how to apply it.

Here's the pertinent section of my package.json. I would really appreciate some help.


        closurecompiler: {
            minify: {

                //files: grunt.file.expandMapping(['lib/*.js'], 'build/', {
                //    rename: function (destBase, destPath) {
                //        return destBase + destPath.replace('.js', '.min.js');
                //    }
                //}),

                files: [
                    {
                        expand: true,     // Enable dynamic expansion.
                        cwd: 'lib/',      // Src matches are relative to this path.
                        src: ['*.js','!*.min.js'],    // Actual pattern(s) to match.
                        dest: 'build/',   // Destination path prefix.
                        ext: '.min.js',   // Dest filepaths will have this extension.
                    },
                ],
                options: {
                    // Any options supported by Closure Compiler, for example:
                    "compilation_level": "SIMPLE_OPTIMIZATIONS",

                    // Plus a simultaneous processes limit
                    "max_processes": 5,

                }

thanks

-greg

thanpolas

unread,
Dec 18, 2013, 9:33:25 AM12/18/13
to closure-comp...@googlegroups.com
care to add it to closureplease.com?

Reply all
Reply to author
Forward
0 new messages