admin管理员组

文章数量:1384278

I would like to use Google Closure Compiler to build a set of CommonJS modules. Can this be done out of the box? Alternatively, is there some simple transformation that can be done to the CommonJS modules to allow them to be consumed by Closure Compiler?

I would like to use Google Closure Compiler to build a set of CommonJS modules. Can this be done out of the box? Alternatively, is there some simple transformation that can be done to the CommonJS modules to allow them to be consumed by Closure Compiler?

Share Improve this question asked Jul 10, 2012 at 22:13 theazureshadowtheazureshadow 10.1k6 gold badges35 silver badges49 bronze badges
Add a ment  | 

1 Answer 1

Reset to default 6

Support has been added to Closure Compiler to make it is easier to work with Common JS and AMD/require.js modules using the following piler flags:

  • --transform_amd_modules
  • --process_mon_js_modules
  • --mon_js_entry_module
  • --mon_js_module_path_prefix

See Experimental support for Common JS and AMD/require.js modules in Closure Compiler

本文标签: javascriptCan Closure Compiler build CommonJS modulesStack Overflow