You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Minification is stripping the basic IIFE wrapper from the cached templates #161
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.
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.
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.
Activity
Add 'use strict' directive to IIFE output
simonua commentedon Oct 17, 2018
While I principally tend to agree with this change, I'm wondering whether introducing
strict modein the function context might break sloppy code contained in the IIFE.simonua commentedon Oct 17, 2018
We currently don't have any tests for IIFE. IMHO, this would necessitate adding some coverage.
dmellstrom commentedon Oct 17, 2018
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.
simonua commentedon Oct 24, 2018
@dmellstrom, thanks very much for adding the test.