Why does Closure Compiler not rename objects with certain names?

后端 未结 1 1950
春和景丽
春和景丽 2021-01-21 16:39

When I test the following code in closure compiler at http://closure-compiler.appspot.com:

// ==ClosureCompiler==
// @output_file_name default.js
// @compilation         


        
相关标签:
1条回答
  • 2021-01-21 17:00

    Update

    As of the 20150315 release of Closure-compiler, the type based optimizations are enabled by default.


    Closure Compiler will not rename properties that have the same name as any property defined on an object in the externs unless the --use_types_for_optimization flag is enabled. See the project FAQ for more details.

    0 讨论(0)
提交回复
热议问题