最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

javascript - Can Closure Compiler build CommonJS modules - Stack Overflow

programmeradmin1浏览0评论

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

发布评论

评论列表(0)

  1. 暂无评论