-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
是否需要增加压缩JS的脚本? #419
Comments
使用以下2种方式都无法得到跟作者一样的压缩结果,作者@zTree能否说明下?
|
等我有空测试看看,毕竟一个是 java 包,一个是 js 包,我也不敢保证 compiler 的 java 和 js 版本可以得到 100% 一样的结果 |
目前看,Java/JS均使用 v20190709版本,压缩后的结果是一样。 但是,对比原始的*.min.js文件,会增加一些信息: var $jscomp=$jscomp||{};$jscomp.scope={};$jscomp.arrayIteratorImpl=function(k){var r=0;return function(){return r<k.length?{done:!1,value:k[r++]}:{done:!0}}};$jscomp.arrayIterator=function(k){return{next:$jscomp.arrayIteratorImpl(k)}};$jscomp.makeIterator=function(k){var r="undefined"!=typeof Symbol&&Symbol.iterator&&k[Symbol.iterator];return r?r.call(k):$jscomp.arrayIterator(k)};
... 其他信息 测试demo的话,并不影响使用。 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
目前是通过Java的工具进行压缩的。
参考Issue #201
可以考虑增加压缩JS的脚本,建议通过npm安装开发依赖google-closure-compiler,这样修改源码后可以输出*.min.js文件。
The text was updated successfully, but these errors were encountered: