As I was re-rolling my JS aggregation patch for Drupal, I stumbled upon an interesting solution to an age old problem I’ve encountered numerous times.
The basis of these compressors is to remove unneeded whitespace, optional characters, and in the case of packer, simplify variable names and function names for maximum compression.
Well, it turns out the solution is simple and involves adding in an optional semi-colon. Here is the example:
Hope this saves you some head banging time, enjoy!