Closed dmellstrom closed 6 years ago
While I principally tend to agree with this change, I'm wondering whether introducing strict mode
in the function context might break sloppy code contained in the IIFE.
We currently don't have any tests for IIFE. IMHO, this would necessitate adding some coverage.
In theory, there won't be any sloppy or even non-static code contained in the IIFE, as it will just contain the template strings plus the surrounding Angular boilerplate added by this plugin. However, I concur that test coverage for IIFE is a good idea. I will add a relevant commit to my PR.
@dmellstrom, thanks very much for adding the test.
My issue is with the
moduleSystem
option, value'IIFE'
.When minifying a build containing concatenated cached templates provided by this plugin, using UglifyJS, the functional wrapper is removed from the prepared templates.