Build warnings
See original GitHub issueType of Issue
[X] Bug Report
[ ] Feature Request
Description
I am trying to figure out what are these warnings and how to fix them. (I have huge lines of code as donation from different team)
Dropping unreachable code [0:2023,8] Declarations in unreachable code! [0:2023,8] Dropping unreachable code [0:2066,12] Declarations in unreachable code! [0:2066,12] Dropping unreachable code [0:2172,8] Declarations in unreachable code! [0:2172,8] Dropping unreachable code [0:2247,8] Declarations in unreachable code! [0:2247,8] Dropping unreachable code [0:2275,8] Declarations in unreachable code! [0:2275,8] Dropping unreachable code [0:2282,8] Declarations in unreachable code! [0:2282,8] Dropping unreachable code [0:2538,8] Declarations in unreachable code! [0:2538,8] Dropping unreachable code [0:2568,8] Declarations in unreachable code! [0:2568,8] Dropping unreachable code [0:2849,8] Declarations in unreachable code! [0:2849,8] Dropping unreachable code [0:3185,8] Declarations in unreachable code! [0:3185,8] Side effects in initialization of unused variable nF [0:4241,40] Side effects in initialization of unused variable UJ [0:4820,40] Dropping unreachable code [0:5050,12] Declarations in unreachable code! [0:5050,12] Side effects in initialization of unused variable ZM [0:5262,40] Side effects in initialization of unused variable AN [0:5356,57] Side effects in initialization of unused variable HN [0:5373,57] Side effects in initialization of unused variable eO [0:5433,57] Side effects in initialization of unused variable zO [0:5530,40] Side effects in initialization of unused variable LP [0:5917,40] Dropping duplicated definition of variable AQ [0:6224,16] Dropping duplicated definition of variable KQ [0:6247,16] Dropping duplicated definition of variable KQ [0:6256,16] Side effects in initialization of unused variable sS [0:6846,40] Side effects in initialization of unused variable zS [0:6858,40] Side effects in initialization of unused variable VS [0:6933,40] Side effects in initialization of unused variable WS [0:6933,56] Side effects in initialization of unused variable lT [0:6982,40] Dropping unreachable code [0:3597,8] Declarations in unreachable code! [0:3597,8]
How To Reproduce
ng build library-name
Expected Behaviour
There should not be any warnings. Or when ng build reports warning at-least provide some sensible information (like file names, method names etc…)for a developer to fix them. Right now looking at the warning reported above I am not able to find out where to start.
Version Information
$ node_modules/.bin/ng-packagr --version
ng-packagr: 4.4.5
@angular/compiler: 7.0.1
rollup: 0.67.4
tsickle: 0.33.1
typescript: 3.1.1
rxjs: 6.3.3
node: 8.12.0
Issue Analytics
- State:
- Created 5 years ago
- Reactions:7
- Comments:7 (1 by maintainers)
Top GitHub Comments
same here.
Minifying UMD bundle
step has warnings aboutDropping side-effect-free statement
Any ideas?
This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem. This action has been performed automatically by a bot.