Version: beta.16
OS: OSX 10.12
So I just ran an ng build -prod --aot using beta.16 and was looking at the output. I noticed main.js has about 20 - 30 instances of Google Copyright notice (one above each block). The same happens for a build without AoT as well actually.
/**
* @license
* Copyright Google Inc. All Rights Reserved.
*
* Use of this source code is governed by an MIT-style license that can be
* found in the LICENSE file at https://angular.io/license
*/
I'm guessing there should only really be one or none of those at the top of the generated dist/main.js
Screenshot: https://www.dropbox.com/s/4cuf1yxtik9drjy/Screenshot%202016-09-28%2010.50.09.png?dl=0
@hansl can you have a look? This must be part of the total bundle size.
I need to talk to the legal team about this. The google ones are probably okay to only put one, but third party libraries might be more complicated.
Just FYI I made a new beta16 project and ran the main bundle through a comment stripper, and non-gzipped size went from 815kb to 764kb.
Speaking of comments.
I'm using material-design-lite and building it from scss. My styles.bundle.js with --prod contains 31 occurrences of every single /* */ comment (not // comments) in _variables.scss as it's included 31 times.
Perhaps I should create a separate issue for this tho?
CSS comments has been solved in #2593.
I see the comments with builds using ngCLI beta.17 as well. Can we strip the credits into a credits.txt file that refers to the compiled _.js/_.css? MIT doesn't require the presence of the copyright notice in binary distributions. Can a *.js file be considered a binary distribution?
Tracked by: https://github.com/angular/angular-cli/issues/4413
Addressed by: https://github.com/angular/angular-cli/pull/4694
This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
_This action has been performed automatically by a bot._