Closed hkaraoglu closed 6 years ago
Hi, thx for the report. Please read my readme from the Headline Attention. This plugin uses yuicompressor and unfortunately it is not supporting ES6. Thx
Duplicate of #3
Possibly yuicompressor can be replaced with ES6 supported compressor.
yes I thought so too but unfortunately this is not on prio list :/
At least, this issue can be solved by creating an output file is as same as input file instead of empty file.
As an easy workaround and a message, what happens there. To create the same output after minifing is confusing, the same as the current behaviour. So a little message like: There where errors, we can't minified it, would be better and to generate the file anyway or not. With an option. But as I said, this could be the workaround for this.
The better solution, maybe for an other ticket is to get rid of the YUI Compressor and use a updated one, like the google closure compiler or what we have.
The plugin doesn't support JS ES6 classes.So this issue is fixed by creating same output file if a file is cannot be minified. (Workaround.) ES6 support will be handled in other issue.
If there is an ES6 class in javascript file. It isn't minified. The plugin just creates an empty file.
Example code:
Output:
Empty file.