Why is it recommended to use concat then uglify when the latter can do both?
问题 I keep seeing the recommendation for making JS files ready for production to be concat then uglify. For example here, in on of Yeoman's grunt tasks. By default the flow is: concat -> uglifyjs. Considering UglifyJS can do both concatenation and minification, why would you ever need both at the same time? Thanks. 回答1: Running a basic test to see if there is a performance difference between executing concat and then uglify vs. just uglify . package.json { "name": "grunt-concat-vs-uglify",